webcomponents.org icon indicating copy to clipboard operation
webcomponents.org copied to clipboard

No support for NPM package previews

Open ergo opened this issue 6 years ago • 4 comments

Hello,

When using https://www.webcomponents.org/preview, there are still checks for bower.json presence so packages that are served from npm cannot be previewed.

Resulting error:

Error - 12 Unable to process element Missing bower.json Currently, only Bower is supported. In the latest tagged version of this repository, ensure there is a valid bower.json.

ergo avatar May 20 '18 14:05 ergo

I ran into this today. Is this just for the preview? Are we able to publish without a bower.json file?

gkjohnson avatar Jun 19 '18 15:06 gkjohnson

@gkjohnson Yes https://www.webcomponents.org/element/polymer-ui-router - I managed to publish an element here from NPM, just struggle with demos working.

ergo avatar Jun 19 '18 15:06 ergo

Interesting -- I'm seeing this error in the demos:

Uncaught TypeError: Failed to resolve module specifier "@webcomponents/shadycss/entrypoints/apply-shim.js". Relative references must start with either "/", "./", or "../".

Looks like the site doesn't resolve the bare module imports. I suppose a pre-built version of the element might be the best way to show a demo?

gkjohnson avatar Jun 19 '18 18:06 gkjohnson

@samuelli is this on the roadmap somewhere?

ergo avatar Sep 25 '18 14:09 ergo