Package Json wrong
I wont to include your npm modules directly as esm but your package json is wrong.
the export: "module" points to "dist/index.js" wich has this code:
export * from './esm-es5/index.js';
but the index.js in esm-es5 is empty
any news to this? I try to use your components in my designer: https://node-projects.github.io/web-component-designer-demo/index.html But for this the exports need to be correct.
Thanks for sharing this with us. I'm one of the maintainers of the project.
Could you please provide me with a simple reproduction where you run into this issue?
As I explained, I create a Designer wich directly can load npm packages from unpkg (or other providers). It then parses the package.json, loads dependecies and at last loads the exports from the package.json
If you look at your package.json here: https://www.npmjs.com/package/@visa/charts?activeTab=explore you see, your "main" export is "dist/index.cjs.js" but if you use es6 modules, you normaly look for the "modules" exoport in the package.json, wich leads to "dist/index.js" wich then leads to the empty import. The cjs export cannot directly be used by the browser. Also the package.json normaly shoul export the es6 code via "export" definition. But at first your "modules" export should work
also when you look at your other export "dist/esm/index.js", it is also empty
https://watch.screencastify.com/v/0cBoi7zxDj5LMQ94nxiM
Thank you for the explanation, we are investigating the issue. I'll get back as soon as I have some sort of a recommendation/resolution to the issue.
Just an extra thought: Would there be a way for you to overwrite the default import behavior on your side (within your designer application)?
i wrote the import behavior, as it i defined in node. why do you deliver empy javascript files? ad I cannot load cjs from the browser. from where should I know wich files to load in your library?
Thank you for the inputs. We are further investigating the problem. As soon as I have some details on this, I'll get back.