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

Packaging issue with @jupyter-widgets/base and backbone when loaded as an esm module #3952

Open
paddymul opened this issue Oct 14, 2024 · 0 comments

Comments

@paddymul
Copy link
Contributor

Description

I am trying to package my widget as a standalone npm module for use in codepen. When packaged with jsdelivr in esm mode, I get the following error loading the JS.

Uncaught TypeError: class heritage n.View is not an object or null
    <anonymous> nativeview.js:53

Reproduce

  1. Go to https://codepen.io/paddymul/pen/qBerprv
  2. https://codepen.io/paddymul/pen/qBerprv
  3. Open the JS console
  4. Look at the type error from nativeview

Expected behavior

I would expect the

Context

This is built from a branch of my code
paddymul/buckaroo#298

I don't think the rest of the fields are relevant since this is a JS bug. But here are the relevant JS config files

Webpack from the branch
https://github.com/paddymul/buckaroo/blob/chore/js-0.7.5-test9-reproduce/webpack.config.js
package.json from the branch
https://github.com/paddymul/buckaroo/blob/chore/js-0.7.5-test9-reproduce/package.json

Package built with yarn run build

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

No branches or pull requests

1 participant