trinary / d3-transform

add an interface for svg transform attributes in d3.js
MIT License
160 stars 17 forks source link

d3-transform is difficult to use with node tools, resulting in "d3 not defined" errors #7

Closed davidbkemp closed 9 years ago

davidbkemp commented 10 years ago

Firstly, thanks for providing d3-transform. I am finding it quite useful and generally pleasure to use.

However, d3-transform is difficult to use with node tools like "browserify".

There are two problems:

It leads to "d3 not defined".

d3-transform.js should only attempt to assign the "transform" method to d3.svg if d3.svg exists, and should also assign the "transform" method to module.exports if module.exports exists. Perhaps even add it to the global namespace if neither d3 nor module.exports are defined.

seliopou commented 9 years ago

Since #8 has been merged, this should be closed.

trinary commented 9 years ago

:+1: Thanks.