MCPcopy
hub / github.com/agalwood/Motrix / convertCommaToLine

Function convertCommaToLine

src/shared/utils/index.js:440–445  ·  view source on GitHub ↗
(text = '')

Source from the content-addressed store, hash-verified

438}
439
440export function convertCommaToLine (text = '') {
441 let arr = text.split(',')
442 arr = arr.map((row) => row.trim())
443 const result = arr.join('\n').trim()
444 return result
445}
446
447export function convertLineToComma (text = '') {
448 const result = text.trim().replace(/(?:\r\n|\r|\n)/g, ',')

Callers

nothing calls this directly

Calls 1

mapMethod · 0.80

Tested by

no test coverage detected