-
Notifications
You must be signed in to change notification settings - Fork 0
join
김태헌 edited this page Sep 26, 2024
·
2 revisions
import { join } from 'mori-ts';
const result = join(' ', ['a', 'b', 'c']);
console.log(result); // 출력: 'a b c'
import { join } from 'mori-ts';
const result = join('-', [1, 2, 3]);
console.log(result); // 출력: '1-2-3'
import { join } from 'mori-ts';
const result = join('..', ['a', 'b', 'c']);
console.log(result); // 출력: 'a..b..c'
import { pipe, range, map, join } from 'mori-ts';
const res = pipe(range(1, 4), map(String), join(','));
console.log(res); // 출력: '1,2,3'
https://github.com/gangnamssal/mori-ts/blob/main/src/test/join.spec.ts