source: node_modules/ramda/es/split.js

main
Last change on this file was d24f17c, checked in by Aleksandar Panovski <apano77@…>, 15 months ago

Initial commit

  • Property mode set to 100644
File size: 717 bytes
Line 
1import invoker from "./invoker.js";
2/**
3 * Splits a string into an array of strings based on the given
4 * separator.
5 *
6 * @func
7 * @memberOf R
8 * @since v0.1.0
9 * @category String
10 * @sig (String | RegExp) -> String -> [String]
11 * @param {String|RegExp} sep The pattern.
12 * @param {String} str The string to separate into an array.
13 * @return {Array} The array of strings from `str` separated by `sep`.
14 * @see R.join
15 * @example
16 *
17 * const pathComponents = R.split('/');
18 * R.tail(pathComponents('/usr/local/bin/node')); //=> ['usr', 'local', 'bin', 'node']
19 *
20 * R.split('.', 'a.b.c.xyz.d'); //=> ['a', 'b', 'c', 'xyz', 'd']
21 */
22
23var split =
24/*#__PURE__*/
25invoker(1, 'split');
26export default split;
Note: See TracBrowser for help on using the repository browser.