jspm / registry

The jspm registry and package.json override service
https://jspm.io
229 stars 256 forks source link

Latest d3 breaks jspm install #1062

Closed rockResolve closed 5 years ago

rockResolve commented 6 years ago

The latest d3 (4.11.0) breaks jspm install at runtime with "Error: (SystemJS) Node child_process module not supported in browsers."

This is caused by d3 package.json main: "build/d3.node.js"

Workaround add jspm override with: jspm -o d3 "{main: 'build/d3.js'}"

See https://github.com/d3/d3-request/issues/24 https://github.com/gatsbyjs/gatsby/issues/2107#issuecomment-330076798

guybedford commented 6 years ago

If you'd like to commit this override to the registry with a PR that would be great.

Does the override { browser: './build/d3.js' } work? I'm surprised that isn't already the browser option though or why that isn't triggering.

rockResolve commented 6 years ago

Yes your browser override is better and works: jspm install d3 -o "{browser: './build/d3.js'}" PR created

guybedford commented 6 years ago

@rockResolve thanks, I don't see the PR here though?