short-name
v0.2.1
Published
Shorten long names.
Downloads
13
Maintainers
Readme
Shorten long names (mostly human names).
Install
$ npm install --save short-name
$ bower install --save short-name
Usage
In node/browserify:
var shortName = require('short-name');
var name = shortName('Tom Marvolo Riddle'); // returns `Tom R.`
In browser:
<script src="dist/short-name.min.js"></script>
<script>
var name = ShortName('Tom Marvolo Riddle');
</script>
License
MIT © Fahad Ibnay Heylaal