Comments (4)
this was implemented a while back
from svelte.
Is there any advantage leaving the rollup config as the default format: 'iife',
vs format: 'esm'.
I found the latter easier to read, but it omits the 'use strict';
It was asked in the comment in this video: https://www.youtube.com/watch?v=1LXEN0Pw6y0&t=5s
Might be better to turn off 'iife' format in rollup, it adds boilerplate you don't need in your output. Try format: 'esm'
from svelte.
format: 'esm'
should only be used if you intend to load the code via <script type='module'>
. Otherwise, the code will be run not in strict mode, and top-level identifiers will pollute the global scope. Also, unless you changed your js minifier configuration, top-level identifiers will not get mangled.
from svelte.
Thx, esm produced runtime errors.
from svelte.
Related Issues (20)
- Preprocess Svelte modules (or deprecate preprocessors?) HOT 6
- enhancement(custom element): make `tag` optional in customElement component options HOT 1
- Svelte5: Calling $derived multiple times HOT 8
- Svelte 5 not reacting to onclick HOT 1
- Error when appending hydration error to head. HOT 6
- Spreadable actions (aka. `use:` directives) HOT 1
- [Svelte 4] bind:this is undefined when running action of child until all children initialize
- Svelte 4 and 5 adds spaces between html elements when mounting components through JavaScript HOT 10
- Custom element props not changeable after assigned value inside component HOT 2
- Svelte automatically binding this to function exports of components HOT 3
- `bind:this` weird behavior HOT 5
- Expose reactivity primitives to users HOT 5
- ReferenceError: $$props is not defined when calling $host()
- CustomElement $effect caused due to props read HOT 7
- `https://svelte.dev` unresponsive, keeps timing out HOT 1
- Web component styles missing when mounted more than once HOT 6
- Consider replacing `export const` and `export function` with a rune HOT 6
- a11y Invalid autocomplete value warning HOT 3
- Feature: Implement {#with } logic block from Ractive.js HOT 2
- Svelte v5 + Sveltekit: Index.d.ts is not generated when exporting components as object properties
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from svelte.