Last updated 6 years ago
Splits a string using a string or regular expression pattern into an array of items.
split :: (String | RegExp pattern, String input) -> Array
import { split } from 'conductor' split(', ', 'Bonsoir, Elliot') // ['Bonsoir', 'Elliot']
import { split } from 'conductor' split(/,\s/, 'Bonsoir, Elliot') // ['Bonsoir', 'Elliot']