Crystal implementation of original NanoID https://github.com/ai/nanoid
Add this to your application's shard.yml
:
dependencies:
nanoid:
github: mamantoha/nanoid.cr
require "nanoid"
Nanoid.generate
# => 3gFI8yZxcfXsXGhB0036l
Nanoid.generate(size: 8, alphabet: "1234567890abcdef")
# => 86984b57
Clone this repository and install dependencies:
shards install
Run tests:
crystal spec
- Fork it ( https://github.com/mamantoha/nanoid.cr/fork )
- Create your feature branch (git checkout -b my-new-feature)
- Commit your changes (git commit -am 'Add some feature')
- Push to the branch (git push origin my-new-feature)
- Create a new Pull Request
- mamantoha Anton Maminov - creator, maintainer
Copyright: 2018 Anton Maminov (anton.maminov@gmail.com)
This library is distributed under the MIT license. Please see the LICENSE file.