@bernardsch/remove-accents

1.0.4 • Public • Published

remove-accents

Simple helper to replace accented characters like éüàôç with their basic form (i.e. euaoc).

The first parameter should be a string otherwhise it will be returned without processing.

The optional second parameter transforms result to lower case if set to true.

Usage :

const {removeAccents} = require('@bernardsch/remove-accents');
const str = "J'étais fatigué.";
console.log(removeAccents(str, true));

Expected : j'etais fatigue.

/@bernardsch/remove-accents/

    Package Sidebar

    Install

    npm i @bernardsch/remove-accents

    Weekly Downloads

    2

    Version

    1.0.4

    License

    ISC

    Unpacked Size

    1.2 kB

    Total Files

    3

    Last publish

    Collaborators

    • bernardsch