html-entities-not-email-friendly
v0.8.8
Published
All HTML entities which are not email template friendly
Downloads
3,276
Maintainers
Readme
Install
This package is pure ESM. If you're not ready yet, install an older version of this program, 0.5.0 (npm i [email protected]
).
npm i html-entities-not-email-friendly
Quick Take
import { strict as assert } from "assert";
import {
notEmailFriendly,
notEmailFriendlySetOnly,
notEmailFriendlyLowercaseSetOnly,
notEmailFriendlyMinLength,
notEmailFriendlyMaxLength,
} from "html-entities-not-email-friendly";
// it's object, mapping entity names to numeric equivalents
assert.equal(Object.keys(notEmailFriendly).length, 1841);
// it's a Set, only listing the bad entity names
assert.equal(notEmailFriendlySetOnly.size, 1841);
// is ≳ email-friendly?
assert.equal(notEmailFriendlySetOnly.has("GreaterTilde"), true);
// no, use numeric entity
// is email-friendly?
assert.equal(notEmailFriendlySetOnly.has("nbsp"), false);
// yes, it's OK
Documentation
Please visit codsen.com for a full description of the API.
Contributing
To report bugs or request features or assistance, raise an issue on GitHub.
Licence
MIT License.
Copyright © 2010-2024 Roy Revelt and other contributors.