Something went wrong. Try again.
doll.systems community website
Something went wrong. Try again.
123456789101112/** Convert a bitmap's horizontal ink runs to exact, integer-aligned SVG cells. * @param {string[]} rows */export const bitmapPath = (rows) => rows .flatMap((row, y) => [...row.matchAll(/#+/g)].map( ({ index, 0: run }) => `M${index} ${y}h${run.length}v1H${index}Z`, ), ) .join('');