This package has been deprecated

Author message:

Package was moved to @vparth/str-esc

str-esc
TypeScript icon, indicating that this package has built-in type declarations

1.0.5 • Public • Published

str-esc

Utility to escape entities in string

Can also split/join strings with respect of escaping

Example

    // import {EscapeService} from 'str-esc';
    const {EscapeService} = require('str-esc');

    let svc = new EscapeService('%');
    svc.encode('100% Y-m-d', ['Y', 'm', 'd']); // '100%% %Y-%m-%d'

    svc = new EscapeService();
    svc.split(', ', 'a, b\\, c, d');    // ['a', 'b, c', 'd']
    svc.join(', ', ['a', 'b, c', 'd']); // 'a, b\\, c, d'

Readme

Keywords

none

Package Sidebar

Install

npm i str-esc

Weekly Downloads

3

Version

1.0.5

License

MIT

Unpacked Size

6.45 kB

Total Files

11

Last publish

Collaborators

  • vparth