npm.io
1.0.5 • Published 9 years ago

escape-split

Licence
MIT
Version
1.0.5
Deps
0
Vulns
0
Weekly
0

escape-split

Splits a string using a delimiter that can be escaped.

Installation

npm install --save escape-split

Usage

const split = require('escape-split')

const splitSpecific = split({ delimiter: <delimiter>, escaper: <escaper> })
const textArray = splitSpecific(<text>)

Note

As of version 1, escape-split only supports single character delimiters and escape values. However, future versions will support multi-character delimiters and escape sequences. It is therefore recommended that you pass empty strings rather than leave the delimiter and escape parameters undefined to not break your code in the future.

Keywords