Files
parcoursup/node_modules/@riotjs/compiler/src/utils/split-string-by-EOL.js

10 lines
292 B
JavaScript
Raw Normal View History

2023-03-05 13:23:23 +01:00
const LINES_RE = /\r\n?|\n/g
/**
* Split a string into a rows array generated from its EOL matches
* @param { string } string [description]
* @returns { Array } array containing all the string rows
*/
export default function splitStringByEOL(string) {
return string.split(LINES_RE)
}