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

Import error #89

Closed
mthh opened this issue Nov 25, 2022 · 2 comments
Closed

Import error #89

mthh opened this issue Nov 25, 2022 · 2 comments

Comments

@mthh
Copy link
Member

mthh commented Nov 25, 2022

Just to clarify (I guess !) the issue reported by @lessthanweb in #83, when importing bertin.js (outside Observable), starting from 1.3.4 you get the following error:

bertin@1.3.4:23 Uncaught TypeError: Cannot read properties of undefined (reading 'contourDensity')
    at bertin@1.3.4:23:32172
    at bertin@1.3.4:1:175
    at bertin@1.3.4:1:254

Import is done as in the README / the examples:

<script src="https://cdn.jsdelivr.net/npm/bertin@1.5.4"></script>

Due to this error the bertin object is empty and it is not possible to call bertin.draw for example.

I think you are missing to include d3-contour in the dependencies of package.json so it fails when importing contourDensity here https://github.com/neocarto/bertin/blob/e44b71355ad0d0a4d79bee00f659e3d3e31ae2c5/src/layers/smooth.js#L5

@neocarto
Copy link
Member

Oops. Thanks Matthieu. I add this

@neocarto
Copy link
Member

neocarto commented Nov 25, 2022

Solved in bertin@1.5.5

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

No branches or pull requests

2 participants