justascii

0.0.2 • Public • Published

Just ASCII

Rewrite JavaScript to escape any non-ASCII characters in string literals. For example, the following input:

console.log("Ich ♥ Bücher");

Becomes the following output:

console.log("Ich \u2665 B\xFCcher");

Only string literals are escaped! If you want to escape Unicode symbols, too, you’ll need something like UglifyJS2.

Dependencies (2)

Dev Dependencies (0)

    Package Sidebar

    Install

    npm i justascii

    Weekly Downloads

    3

    Version

    0.0.2

    License

    BSD-3-Clause

    Last publish

    Collaborators

    • mbostock