Svelte: SVG baseVal

Created on 6 Jun 2018  路  4Comments  路  Source: sveltejs/svelte

It turns out that this...

rect.x.baseVal.value = 200;

...is faster than this:

rect.setAttribute('x', 200);

This might be something we can use to our benefit.

enhancement internals perf

Most helpful comment

@antony awesome, going to start on this! Will do some research to setup a baseline/benchmark for comparison :tada:

All 4 comments

It might improve the performance of http://rethinking-reactivity.surge.sh/svelte-svg/, which would be fun

Is anyone working on this? I can pick it up if not.

@NazimAli2017 I doubt very much anyone is working on this - it's more than 2 years old with no comments. We'd welcome your contributions :)

@antony awesome, going to start on this! Will do some research to setup a baseline/benchmark for comparison :tada:

Was this page helpful?
0 / 5 - 0 ratings

Related issues

clitetailor picture clitetailor  路  3Comments

rob-balfre picture rob-balfre  路  3Comments

Rich-Harris picture Rich-Harris  路  3Comments

robnagler picture robnagler  路  3Comments

plumpNation picture plumpNation  路  3Comments