Closed bmschmidt closed 6 years ago
This is a task for @Fil, but my recommendation is that these imports be removed, and instead the code is inlined in this library.
Alternatively, they should be changed to top-level exports from d3-geo-projection, and then they can be imported here, e.g.:
import {polyhedralMatrix} from "d3-geo-projection";
it should work now (I inlined the code as Mike suggested)
Trying to bundle this in a webpack-based app, I find it breaks because it assumes a hardcoded location for
node_modules
in many places, eg (from here).yielding many errors like
Since I'm also requiring d3-geo-projection, these files are not inside the d3-geo-polygon folder: they're located at something like '../../../node_modules', maybe a level higher.
I'm able to get a successful install by just removing the prefix in all javascript files and importing straight from (eg)
d3-geo-projection/src/math
Can file a pull request if desired, but I don't know if that fix will break in other locations.
Thanks!