kebab-hash
Given an input string, convert to kebab-case and append a hash. Avoids kebab case collisions.
Last updated 8 years ago by chmac .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install kebab-hash 
SYNC missed versions from official npm registry.

kebab-hash

Given an input string, convert to kebab-case and append a hash. Avoids kebab case collisions.

Use Case

If you convert URLs to kebab case then /foo-bar and /foo/bar both become foo-bar. kebab-hash solves this problem by appending a hash of the input to the output string. So these two examples become foo-bar-096 and foo-bar-1df instead.

Node only

This package is designed for use on the server (node) not in the browser. PRs welcome.

Current Tags

  • 0.1.2                                ...           latest (8 years ago)

3 Versions

  • 0.1.2                                ...           8 years ago
  • 0.1.1                                ...           8 years ago
  • 0.1.0                                ...           8 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 1
Last Month 1
Dependencies (1)
Dev Dependencies (7)
Dependents (2)

Copyright 2013 - present © cnpmjs.org | Home |