from - nodef/extra-string GitHub Wiki

Create string from iterable, like Array.from().

const from = require('@extra-string/from');
// from(<iterable>, [mapFn], [thisArg])

from(['a', 'b']);
// 'ab'
from('abc', (v) => String.fromCharCode(v.charCodeAt()+1));
// 'bcd'
from(new Set().add('a').add('b'));
// 'ab'
from(new Map().set('a', 1).set('b', 2));
// 'a,1b,2'

extra-string

⚠️ **GitHub.com Fallback** ⚠️