UNPKG

foxts

Version:

Opinionated collection of common TypeScript utils by @SukkaW

1 lines 147 B
function t(t,e){const n=Math.ceil(t.length/e),r=Array(n);let c=0,l=0;for(let o=0;o<n;o++)l=(c=o*e)+e,r[o]=t.slice(c,l);return r}export{t as chunk};