escape-split
v1.0.5
Published
Splits a string with delimiters that can be escaped, unassuming parameter values.
Downloads
548
Readme
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.