Clone and edit this document
Runkit
Runkit
home page
user forum
new notebook
clone notebook
download notebook
support & documentation
log in
sign up
new notebook
help & feedback
clone this notebook
download this notebook
Sign In
Sign Up
data-cleaning-diacritic-marks
node v8.17.0
version:
2.0.0
endpoint
share
tweet
When diacritic marks in text make search & comparison impossible, wink-helpers comes to rescue!
// Search or comparison fails in such cases: console.log( 'Nestlé' === 'Nestle' ); // -> false // Load wink helpers and obtain normalize api for string. var normalize = require( 'wink-helpers' ).string.normalize; // Use normalize api to resolve the problem. console.log( normalize( 'Nestlé' ) ); // -> nestle console.log( normalize( 'Nestlé' ) === normalize( 'Nestle' )); // -> true
Loading…
no comments
sign in
to comment