The string value to be split into substrings.
The object which contains a Symbol.split method, Omitting splitter or passing an object that doesn't contain a Symbol.split causes it to return an array with the calling string as a single element.
Optional
limit: numberA non-negative integer specifying a limit on the number of substrings to be included in the array. If provided, splits the string at each occurrence of the specified separator, but stops when limit entries have been placed in the array. Any leftover text is not included in the array at all.
An Array of strings, split at each point where the separator occurs in the given string.
The
strSymSplit()
splits a string into substrings using theSymbol.split
method from the splitter object to provide custom behavior. If the runtime supports symbols then the default runtimesplit
method will be called, It will use getKnownSymbol to get the WellKnownSymbols.split symbol which will return the runtime symbol or the polyfill symbol when not supported by the runtime.Since
0.9.1
Example