gka/d3-jetpack

api tweaks

1wheel opened this issue · 3 comments

Can leave the old functions in while updating the docs and adding new aliases.

parentSel

I usually do var sel = d3.select('.graph').html() at the start of my render function. d3.conventions({sel}) is cleaner than d3.conventions({parentSel: sel}).

appendMany

I think dataAppend is easier to teach; the first argument is the data, the second is what you're appending. Or manyAppend?

ƒ

Not sure this is necessary anymore with ES6. Maybe remove from the examples?

Maybe arrayAppend?

gka commented

how about just appendMany("div", data) ?

gka commented

for a grace period we could add in some code that detects whether the string argument is first or second and console.warn a

DEPRECATED: jetpack's appendMany order of arguments has changed.
It's appendMany("div", data) from now on.