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

Inline demo not working and component is not getting updated in web components after release.

Open Kedar-K opened this issue 5 years ago • 4 comments

Hello, I recently published an element in webcomponents.org and I realised that inline demos are not working and even demo/index.html is not working but it works fine in my laptop when i use polymer serve command. How do i make it work? This is the link for element.

Kedar-K avatar Oct 13 '18 17:10 Kedar-K

Probably related to the fact that rawgit is going to shut down soon. They stopped caching new pages but still serve old ones.

MichaelKovalchuk avatar Oct 18 '18 16:10 MichaelKovalchuk

Any workaround / plan to have demo on new components work again ? This was really handy ; )

christophe-g avatar Oct 29 '18 21:10 christophe-g

Can confirm it's to do with RawGit, I get an error 400 with the message

Invalid response from rawgit. Received 403 for https://cdn.rawgit.com/link2twenty/l2t-fab-footer/1.0.1/l2t-fab-footer/l2t-fab-footer.js

Following the link leads to a 403 with the message

RawGit will soon shut down and is no longer serving new repos. Please visit https://rawgit.com for more details.

@samuelli is there a plan in works to fix this? Maybe migrating to https://gitcdn.xyz/ or https://www.jsdelivr.com/

Link2Twenty avatar Nov 23 '18 09:11 Link2Twenty

As a quick hack for my latest element, I've made a webpack bundle and uploaded it to its own branch on GitHub

https://github.com/Link2Twenty/l2t-fab-footer/blob/build/webpack.config.js here's the webpack config file. Then the import looks like this

<script type="module">
  import 'https://cdn.jsdelivr.net/gh/Link2Twenty/l2t-fab-footer@build/build/bundle.js';
</script>

The inline then works https://www.webcomponents.org/element/l2t-fab-footer

The build will have to be updated every time I do a new release but that's not too much effort.

Link2Twenty avatar Nov 23 '18 11:11 Link2Twenty