react-tesna-utils
Version:
A versatile utility library featuring optimized functions for data manipulation, clipboard handling, text truncation, comparison, validation, and more. Designed for modern JavaScript and TypeScript projects with efficient and reusable solutions.
9 lines (8 loc) • 314 B
JavaScript
Object.defineProperty(exports, "__esModule", { value: true });
exports.getChunksFromString = void 0;
const getChunksFromString = (str, chunkSize) => {
const regexChunk = new RegExp(`.{1,${chunkSize}}`, 'g');
return str.match(regexChunk);
};
exports.getChunksFromString = getChunksFromString;
;