Learn about our RFC process, Open RFC meetings & more.Join in the discussion! »

string-normalize-es6

0.1.1 • Public • Published

string-normalize-es6 Build Status

Normalize string using ES6 String.Prototype.Normalize

Install

$ yarn add string-normalize-es6

Usage

const stringNormalize = require('string-normalize-es6');
 
stringNormalize('Crème Brulée');
//=> 'Creme Brulee'
 
stringNormalize(123);
//=> null

API

stringNormalize(input)

input

Type: string

String you want to normalize to NFD.

Contribute

The module is based on this answer on Stackoverflow. I'm not completely sure the this is the correct implementation and maybe we can also specify the normalization type as argument. PR welcome! 🚀

Test

$ yarn test

License

MIT © LasaleFamine

Install

npm i string-normalize-es6

DownloadsWeekly Downloads

6

Version

0.1.1

License

MIT

Last publish

Collaborators

  • avatar