You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Note: since no code is bundled, you will ship quite a bit more data to the user.
If you try to import {LitElement, html} from "lit" and don't use a bundler like rollup or webpack, you will get the error Failed to resolve module specifier "@lit/reactive-element". Relative references must start with either "/", "./", or "../"
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Note: since no code is bundled, you will ship quite a bit more data to the user.
If you try to
import {LitElement, html} from "lit"
and don't use a bundler like rollup or webpack, you will get the errorFailed to resolve module specifier "@lit/reactive-element". Relative references must start with either "/", "./", or "../"
Through import maps, you can help the browser retrieve the correct files. However, as of today, only Edge and Chrome support import maps.
All you have to do is paste this in the
<head>
section of your html file:A minimal working example looks like this:
Beta Was this translation helpful? Give feedback.
All reactions