Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@bustle/slugify

Package Overview
Dependencies
Maintainers
17
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@bustle/slugify - npm Package Compare versions

Comparing version 1.0.1 to 1.1.1

yarn.lock

1

index.js

@@ -23,2 +23,3 @@ const slug = require('slug')

module.exports = {
slug: slugify,
slugUser: user => makeSlug(user.id, user.name),

@@ -25,0 +26,0 @@ slugPost: post => makeSlug(post.id, post.title),

2

package.json
{
"name": "@bustle/slugify",
"version": "1.0.1",
"version": "1.1.1",
"description": "Slug all our things into slugs",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -18,2 +18,8 @@ # bustle slugify

## slug(string) -> slug
Slug any string
```js
assert.equal(slug('a generic string'), 'a-generic-string')
```
## slugUser(user:{id!, name}) -> slug

@@ -20,0 +26,0 @@ Users have the id last, don't use this until [nighthawk](https://github.com/bustlelabs/nighthawk/issues/331) can deal with it.

@@ -5,2 +5,3 @@ /* eslint-env mocha */

const slug = slugify.slug
const slugUser = slugify.slugUser

@@ -11,2 +12,8 @@ const slugArticle = slugify.slugArticle

describe('slugify', () => {
describe('#slug', () => {
it('should slugify a string', () => {
assert.equal(slug('a generic string'), 'a-generic-string')
})
})
describe('#slugUser', () => {

@@ -13,0 +20,0 @@ it('should put the id at the end', () => {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc