Sha256: 5c9375873041273bf031b9362b51e58216cc6478da5cb68b496446d9a51a3076

Contents?: true

Size: 459 Bytes

Versions: 11

Compression:

Stored size: 459 Bytes

Contents

unique-slug
===========

Generate a unique character string suitible for use in files and URLs.

```
var uniqueSlug = require('unique-slug')

var randomSlug = uniqueSlug()
var fileSlug = uniqueSlug('/etc/passwd')
```

### uniqueSlug(*str*) → String (8 chars)

If *str* is passed in then the return value will be its murmur hash in
hex.

If *str* is not passed in, it will be 4 bytes coverted into 8 hex
characters, generated by `crypto.pseudoRandomBytes`.

Version data entries

11 entries across 10 versions & 5 rubygems

Version Path
optimacms-0.4.3 spec/dummy/node_modules/unique-slug/README.md
optimacms-0.4.2 spec/dummy/node_modules/unique-slug/README.md
locomotivecms-4.0.0.alpha1 app/javascript/node_modules/unique-slug/README.md
locomotivecms-3.4.0 app/javascript/node_modules/unique-slug/README.md
cortex-0.1.3 spec/dummy/node_modules/unique-slug/README.md
dragonfly_puppeteer-0.1.0 node_modules/unique-slug/README.md
node-compiler-0.9.1 vendor/node/deps/npm/node_modules/unique-filename/node_modules/unique-slug/README.md
node-compiler-0.9.0 vendor/node-v7.2.1/deps/npm/node_modules/unique-filename/node_modules/unique-slug/README.md
node-compiler-0.8.0 vendor/node-v7.2.0/deps/npm/node_modules/unique-filename/node_modules/unique-slug/README.md
node-compiler-0.7.0 vendor/node-v7.1.0/deps/npm/node_modules/unique-filename/node_modules/unique-slug/README.md
node-compiler-0.7.0 vendor/node-v6.9.1/deps/npm/node_modules/unique-filename/node_modules/unique-slug/README.md