3 ms·
> context.reset is kinda funny. Most high-performance canvas apps will never want to use it. For that matter you want to set all properties as little as possibl
by leeoniya 5y ago
> context.reset is kinda funny. Most high-performance canvas apps will never want to use it. For that matter you want to set all properties as little as possible, especially setting things like context.font, which are slow even if you're setting it to the same value. (Or it was, I haven't tested that in several years).
yes, ctx.font mutation still sucks very badly. and you cannot avoid it during drag-resizing a canvas, which is miserable. (i maintain a high perf charting lib).
my additional annoyances:
https://news.ycombinator.com/item?id=30554387 https://news.ycombinator.com/item?id=30554387