It seems the examples of the code running in stackblitz have no reference to index.js. It is never included in the page. How is the custom element code even running? The only script links are to node_modules.
Hey Lorless, stackblitz does some magic that adds the index.js. If you're trying it out locally you should add a <script type="module" src="./index.js"> to your index.html.
Hi Pascal,
It seems the examples of the code running in stackblitz have no reference to index.js. It is never included in the page. How is the custom element code even running? The only script links are to node_modules.
Hey Lorless, stackblitz does some magic that adds the index.js. If you're trying it out locally you should add a
<script type="module" src="./index.js">
to yourindex.html
.I'd additionally install es-dev-server as explained here. In case local development environment is not already set.
Thanks! I wondered whether something like that was happening. The tutorial was good.