Normalize Special Characters

node v16.10.0
version: 1.0.0
endpointsharetweet
var _ = require("lodash@4.17.15") _.assign(global, require("lodash-doc-globals")) Object.observe = _.noop
const clearSpecialCharacter = (text) => _.deburr(text).toLowerCase().replaceAll(/\s{2,}|\W/g, ""); clearSpecialCharacter('Coração \* Ésteván'); // => 'deja vu'
Created from: https://lodash.com/docs/4.17.15#deburr
Loading…

no comments

    sign in to comment