Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to import - d3 #810

Open
mbostock opened this issue Mar 13, 2024 · 1 comment
Open

Failed to import - d3 #810

mbostock opened this issue Mar 13, 2024 · 1 comment
Labels
browser Not working in Browser

Comments

@mbostock
Copy link

mbostock commented Mar 13, 2024

Failing module

import {schemeObservable10} from "https://esm.sh/d3";

Error message

After onload I got this:

Uncaught SyntaxError: The requested module 'https://esm.sh/d3' does not provide an export named 'schemeObservable10' (at test.html:4:9)

Additional info

The built version of d3 currently resolves the d3-scale-chromatic dependency to 3.0.0, but the latest release of d3-scale-chromatic is 3.1.0.

https://esm.sh/d3@7.9.0

  • esm.sh version: N/A
  • Browser version: N/A
@mootari
Copy link

mootari commented May 24, 2024

Unfortunately this is still an issue and extends to other packages that pull in d3.

For d3 itself a workaround appears to be to append a cache breaker, e.g. https://esm.sh/d3@7.9.0?foo. In another case I was able to circumvent the cached dependency by adding ?bundle-deps: https://esm.sh/gh/observablehq/plot@v0.6.14?bundle-deps&dev

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
browser Not working in Browser
Projects
None yet
Development

No branches or pull requests

2 participants