代码拉取完成,页面将自动刷新
??
alongside logical operators (#5558)<slot slot="...">
(#5475)get
function in svelte/store
(#5483)end
field on ASTs for non-top-level <style>
elements (#5487){#if}
inside {#await}
with destructuring (#5508)<slot slot="...">
(#2079)get
function in svelte/store
(#5269)EventSource
to known globals (#5463)~
/+
combinators and {...spread}
attributes (#5465){#key}
block for keying arbitrary content on an expression (#1469)|nonpassive
event modifier, explicitly passing passive: false
(#2068)~
and +
combinators (#3104){#each}
not reacting to key changing (#5444)missing-declaration
warning with use:obj.method
(#5451)use:obj.method
as actions (#3935)_
as numeric separator (#5407)[open]
selectors on <details>
elements (#5421)import.meta
in template expressions (#5422)*
(#5370){#await}
s with no {:catch}
getting stuck unresolved if the promise rejects (#5401)null
rather than undefined
for coerced bound value of <input type="number">
(#1701)$$slots
(#2106){#await}
block with no {:catch}
gets a rejection (#5129)createEventDispatcher
(#5211)unused-css-selector
warning (#5252)<Namespaced.Component/>
s in child {#await}
/{#each}
contexts (#5255)<svelte:component>
in {:catch}
(#5259)<input>
value
to undefined
when it has spread attributes (#5270){#each}
involving a store (#5286).innerHTML
(#5315)$$props
in slot fallback content (#5367)$$props
to a <slot>
(#3364){#each}
{:else}
(#4970)$$props
and $$restProps
(#4993, #5118)a11y-label-has-associated-control
warning (#5074)a11y-media-has-caption
warning (#5075)bind:group
when using contextual reference (#5174)??
) and optional chaining (?.
) operators (#1972)import.meta
(#4379)<input>
values when they're changed when there are spread attributes (#4418){@html}
when used at the root of a slot, at the root of a component, or in <svelte:head>
(#5012, #5071)contenteditable
elements (#5018)import
ed value that is used as a store and is also mutated (#5019)a11y-missing-content
warning on elements with contenteditable
bindings (#5020)this
in inline function expressions in the template (#5033)$store
at compile time when top-level store
has been shadowed (#5048)<select>
with one-way value
binding when the available <option>
s change (#5051)tweened
types so the .set()
and .update()
options are optional (#5062)bind:this
inside {#each}
block (#5067)<script>
and <style>
tags (#5080)bind:group
inside {#each}
(#3243)bind:this
variable (#4636)bind:group
when multiple options have the same value (#4397)bind:this
to the value of an {#each}
block (#4517){#each}
variable (#4574, #4744){#each}
values that shadow outer names (#4757):global()
does not contain a selector (#4930)<select>
with bind:value
when the available <option>
s change (#1764)muted
binding for media elements (#2998)<input>
to undefined
(#3569)<select multiple>
when there are spread attributes (#4392)<slot>
with context overflow (#4624)a11y-no-onchange
warning (#4788)use:
actions being recreated when a keyed {#each}
is reordered (#4693){@html}
when using tags that can only appear inside certain tags (#4852){#each}
context (#4879){#await}
(#4560, #4810)tweened
store when set using duration: 0
(#4799, #4846)value
attribute with bind:group
and attribute spread (#4803){#if}
block involving static condition, dynamic condition, and inline component (#4840)a11y-img-redundant-alt
and value-less alt
attribute (#4777)a11y-img-redundant-alt
and dynamic alt
attribute (#4770)tweened
store using duration: 0
instantly update the value (#4399)bind:this
inside {#each}
block (#4686)href
for <a>
with name
or id
(#4697)a11y-invalid-attribute
warning for href="javascript:..."
(#4733)a11y-img-redundant-alt
warning (#4750)<Anchor>
(#4768)globalThis
rather than globals
for the benefit of non-Node servers and web workers (#3561, #4545){#await ... catch ...}
syntax shorthand (#3623)<svelte:component/>
within <slot/>
(#4597){#if}
blocks (#4629)<input type="number">
updates (#4631, #4687){#if}
block directly within <slot/>
(#4703){#await}
blocks (#1851)<svelte:self>
to be used in a slot (#2798)$$restProps
(#2930)const
variables (#4479){#each}
blocks (#4491){#each}
blocks with {:else}
(#4536, #4549)dev
mode, display a runtime warning when a component is passed an unexpected slot (#1020, #1447)vars
array, correctly indicate whether module
variables are mutated
or reassigned
(#3215){#if}
blocks (#4263)dev
mode, check for unknown props even if the component has no writable props (#4323)$capture_state
(#4463)$$props
as updates to a store called $props
(#4368)value
parameter name used in contextual bindings (#4445){#each}
blocks using strings (#4450)$capture_state
/$inject_state
now act on the component's entire state, rather than its props (#3822)<Foo/>
and Foo
is dynamic (#4331)svelte/register
in dev mode (#4364){#each}
blocks (#4408){shorthand}
attribute/prop names (#4325)flush()
by not using .shift()
(#4356){#each}
(#4372){expressions}
(#4372)++foo.bar
(#4393):global()
but contain a scoped portion (#4314)onMount
(#3218)<slot>
inside an {#if}
or other block (#4292)derived
stores (#4298){#each}
(#4301)<title>
when starting from SSR-generated code with hydratable: true
(#4310){#await}
block (#4012)let:
variables in sibling attributes on slot root (#4173)~=
and class selector matching against values separated by any whitespace characters (#4242)await
ed expressions that need parentheses (#4267)<svelte:body>
events (#4278)<head>
elements when compiling with hydratable: true
(#4258)<head>
elements during hydration so they aren't duplicated (#1607){:else}
in {#each}
(#4202)<title>
in SSR mode when multiple components provide one (#4250)bind:
elsewhere (#4155)let:
directives (#2751)<tspan>
s in <svg>
s (#3998)referenced
in vars
for tooling (#4081)$$invalidate
calls from init block (#4018){:then}
without resolved value containing {#each}
(#4022)loopGuardTimeout
(#4034){:then}
containing {#if}
(#4044)import
s in format: 'cjs'
output mode (#4055)export function foo() {}
(#3954)context="module"
exports with the same name as an instance variable (#3983){#each}
blocks referring to global variables (#3992)requestAnimationFrame
callback argument for smoother transitions (#4014)listen_dev
argument order (#4016)seeking
and ended
bindings to media elements (#3650)videoWidth
and videoHeight
bindings to video elements (#3927)flip
animation (#3555)aria-hidden="true"
to objects generated when adding resize-listeners, to improve accessibility (#3948)loopGuardTimeout
option that augments for
/while
loops to prevent infinite loops, primarily for use in the REPL (#3887)Also:
{#each}
context not shadowing outer scope when using bind:
(#1565){...spread}
attributes with other features (#2721, #2916, #3421, #3681, #3764, #3790)break $
(#2828)export { ... as ... }
(#3508){@debug}
tags with no dependencies (#3588)bind:this
binding to a store (#3591)HTMLElement
check before extending class (#3608)location
as a known global (#3619){#await}
with {:catch}
but no {:then}
(#3623)<slot/>
s (#3631){#await}
(#3660)createEventDispatcher()
after component instantiation (#3667)<svelte:window>
bindings to stores (#3832)<svelte:options tag="...">
without customElement: true
option (#3782)Event
to list of known globals (#3810)easing
param on fade
transition (#3823)block
(#3854)input.files
(#3828)"undefined"
class name (#3876)src
attribute unless changed (#3579)<script>
block (#3745)@
symbols in props, again (#3545)document
in development to facilitate dev tooling (#3005)$capture_state
and $inject_state
HMR hooks in dev mode (#3148)<script>
(#3537)null
text when hydrating (#3379)bind:currentTime
more reliable (#3524)blur
transition (#3477)<input type="number">
edge case with spread props (#3426)!important
inline styles (#1834)is
attribute on elements, with a warning (#3182)self
event modifier (#3372)let
variables are dynamic for slots (#3354)svelte-ignore
comments (#3351)$
or $$...
is referenced as global (#3272)class
on element with scoped styles from rendering as undefined
(#3283)async
/*
when hoisting functions (#3179)raf
a noop on server (#3324)change
event for file inputs (#3226)$$props
(#3286)class:
combination (#3242):root
selector (#3250)get
(#3153)let
values to bindings (#3140)@
symbols in props (#3173)onMount
functions in correct order, and before initial afterUpdate
functions (#2281)=
characters (#3149)bind:this
(#2806)@
in dev mode debug filename (#3114)innerHTML
and textContent
bindings for contenteditable
elements (#2996)onDestroy
functions, not just for detaching components (#3058){#each}
blocks (#713)bind:this
on components (#2333)$$props
(#2725)requestAnimationFrame
context (#2933)once
modifier on component events (#2654)<title>
tags (#2980){@html ...}
in head (#2880)$$props
(#2881)svelte/store
being bundled (#2786)requestAnimationFrame
as a no-op on the server (#2856)raw
property to AST's Text
nodes (#2714)<details bind:open>
(#2854)customElement: true
with no <svelte:options>
(#2821)svelte/store
(#2795)spring
to work server-side (#2773)tag
(#2417)svelte/store
to TypeScript (#2733)debug
tags to include hoisted values (#2764)=
(#1513)const
values (#2728)<Foo.Bar/>
) (#2743)window
and document
to expected globals (#2722)Object.prototype
-related bugs (#2696)derived
as for other stores (#2644)$:
(#2176)spring
animations, and add hard
/soft
options (#2627)parse
and walk
functions (#2661, #2534)each
block destructuring patterns (#2647, #2658)setAttribute
to change form
property on form elements (#1742)<figcaption>
is non-direct descendant of <figure>
(#2582)insertBefore
(#2573)$$scope
from being spread onto an element (#2520)<script>
(#2435)const
variables (#2285)alert
, confirm
and prompt
to known globals (#2648)unsubscribe
method, providing native RxJS support (#2549)classList
fix (#1868)stats.props
(#1837)<svelte:document>
tag (#1484){#if}
blocks (#1780)<svelte:head>
(#1774)onerror
option (#1745)destroy
is called before mount
(#1653)scroll
binding more efficient (#1579)import()
in template expressionsclass
directive shorthand and encapsulate styles (#1695)toggleClass
(#1685){@debug}
in SSR (#1659)
as empty whitespace (#1658)style.cssText
in spread attributes (#1684)--shared
CLI option (#1649)onstate
before fragment is rendered (#1522){@debug}
tags (#1647){@debug}
tag, for inspecting values in templates in dev mode (#1635)ref
names (#1613)null
consistently in tags (#1598)<input type=file bind:files>
(#1608)addResizeHandler
(#1600)else
block (#1589).innerHTML
was being used to create child elements when it shouldn't (#1581)template.content
instead of template
where appropriate (#1571)<svelte:component>
if nestedTransitions
is true (#1568)data-foo
props (#887)transitionManager
when necessary (#1514)refs.*
as callee (#1526)__svelte_meta
object to elements in dev mode, containing source info (#1499)bind:online
in dev mode (#1502)if
block branches have outros (#1492)skipIntroByDefault
(#1460)animate
directive (#1454)skipIntroByDefault
compiler option and intro: true
init option (#1448)nestedTransitions
compiler option (#1451)nestedTransitions
is true (#1211)1 - t
as second argument to transition functions (#1452)Promise
to whitelisted globals (#1441)await
blocks (#956)await
blocks with no dynamic content (#1417)ref
directives prevent HTMLified content (#1407)each
key in child scope (#1397)bind:offsetWidth
, bind:offsetHeight
, bind:clientWidth
and bind:clientHeight
(#984)each
blocks (#1287)stats
when options.generate
is false
(#1368)this
value in custom event handlers (#1297)each
values lazily (#1286)await
blocks (#1251)changed
based on state, not expected props (#1356)See the blog post for information on how to upgrade your apps
onstate
and onupdate
hooks, remove component.observe
method (#1197)svelte.compile
(#1298)validate
and Stylesheet
from public API (#1348)Store
support, and cascading disabled (#1348)hash
property from AST (#1348)loc
property to start
in warnings and errors (#1348)component.get
(#1347)observe
method to be overwrittenonstate
and onupdate
lifecycle hooks and deprecate component.observe
(#1197)on
and fire
to Store
, deprecate onchange
and observe
(#1344)code
field to errors and warnings (#474)<style>
tags (#1339)parser: 'v2'
option (#1318)multiple
attributes on bound <select>
elements (#1331)console
etc in component events (#1278)multiple
attribute for bound select (#1270)<:Window>
(#1268)svelte.compile
returns an object with { js, css, ast }
properties, where js
and css
are { code, map }
objects (#1298)teardown
in custom event handlers (#531)each
block (#1291)each
block (#1295)svg
, tag
, and props
properties (#1284)preserveComments
option in SSR mode (#1265)setAttribute
to set input types (#1209)component
and state
to be context names (#1213)@supports
rules when cascade: false
(#1215)_mount
method (#1201)key
for children of keyed each blocks (#1202)$foo
in dev mode (#1181)onchange
handlers (#1177)["default"]
instead of .default
in legacy mode (#1166)options.name
begins with non-alphabetical character (#1179)immutable
compiler option for Svelte and runtime option for Store
(#1146)oncreate
when custom element is attached (#1117)await
blocks using stale state (#1131)<noscript>
elements in DOM mode (#1108)<script>
/<style>
tags (#1163)<style>
tags (#1163)oncreate
hooks depth-first, top-to-bottom (#1135)feed
aria role to expected roles when doing a11y checks (#1124)<style>
contents alone (#1091)await
blocks (#1061)oncreate
for components in await
blocks (#1061)<script>
and <style>
(#1082)store
option in SSR mode (#1107)scroll
bindings (#1071)<a>
attributes with xlink:href
(#1008)<:Head>
(#1026)<title>
(#1027)bind: false
option to disable two-way binding (#54)html
from SSR compiler render().toString()
methods (#1044)<option>
outside <select>
(#1022)store
to children in SSR mode (#1029)store
as a component property (#1028)<:Head>
component for injecting contents into document head (#1013))render(...)
method now returns a { html, css: { code, map }, head }
object (#1013)renderCss(...)
method is deprecated (#1013)preload
function to components (#1015)this.root
on nested components (#1023)_recompute
(#1012)await
blocks in slots (#1018)toString
on CompileError
(#1016)import(...)
inside <script>
tags (#1003)await...then
shorthand (#957)dataset
on SVG nodes (#982)<figcaption>
a11y warning (#991)event
to expectedProperties
(#972)set
arguments in dev mode (#990)filename
through to preprocessors (#983)Store
class to manage global state (#930)aria-current
(#953)extensions
(#939)<:Window>
components (#943)each
block (#932)<:Window bind:online/>
(#936)indeterminate
binding for checkbox inputs (#910)<option>
children as value
attribute if none exists (#928)innerHTML
with <option>
elements (#915)dataset
unless legacy
is true (#858)prepare
script to facilitate installing from git (#923)async
keyword when extracting functions (#904)data
on initialisation (#891)onwarn
and onerror
receive default handlers as second arguments (#883)muted
as boolean property on <audio>
elements (#886)each
block contexts (#889)innerHTML
(#866)textContent
and innerHTML
expressions (#868)console.*
calls in event handlers (#782)textContent
and innerHTML
where appropriate (#23)slot='...'
inside custom elements (#827)slot='...'
inside if/each blocks (#849)timeRangesToArray
(#837)buffered
, seekable
, played
bindings to media elements (#819)class
properties in legacy mode (#830)lang
attribute on <html>
(#828)style
attributes where possible (#455)set
and get
continue to work until destroy
is complete (#788)<slot>
elements (#790)options
to instance (#550, #777)<style>
tag (#757){{yield}}
with <slot>
— adds fallback content named slots, and options.slots
(#763)anchor
initialisation option, alongside target
(#784)legacy
compile option, which adds IE9 compatibility (#773)@keyframes
atrules with from
and to
selectors (#774)create()
on new iterations of static each blocks (#762)change
events as well as input
events to bind range inputs (#740)set
and destroy
with noop
when component is destroyed (#744)ref:foo
as a CSS selector (#693)cascade: false
(#743)ondestroy
callbacks fire (#706)on:foo
equals on:foo='fire("foo", event)
(#638)refs.*
in event handlers, and validate them (#686)#
characters (#722)intro.start
and outro.start
events (#702)cssMap
property to compiler output (#698)hydrate
is true but hydratable
was false (#664)<select>
binding in loop (#685)oncreate
functions prematurely (#694)get_block
(#667)ast
in svelte.compile
return value (#632)<select>
binding, if unspecified (#639)<select>
bindings (i.e. the dependencies of their <option>
values) (#639)<style>
tags (#634)type
attribute for unbound inputs (#620)addEventListener
and removeEventListener
directives (#621)mount
and unmount
. This is potentially a breaking change if your components import other components that were precompiled with an earlier version of Svelte (#592)cascade
option, which prevents styles affecting child components if false
, unless selectors are wrapped in :global(...)
and keyframe declaration IDs are prefixed with -global-
. This will become the default behaviour in v2 (#583)number
/range
inputs to undefined
, not 0
(#584)helpers
if referenced, not just for call expressions (#575)<textarea>
children (#599)<textarea>
value attributes and children as equivalent, and fail validation if both are present (#599)<textarea>
SSR (#599)transitionManager
is treeshakeable (#593)node.style.animation
is undefined (#587)<select>
elements (#590)if
blocks and their anchors (#569)<style>
tags (#554)if
blocks with else
blocks (#540){{yield}}
block content is injected into the right place (#561)if
blocks (#565)<:Window>
tags (#565)generateKeyframes
, so that CSS transitions workquerySelector(':checked')
instead of selectedOptions
(#539)bind:checked
that doesn't belong to a checkbox input (#529)<select>
attributes after children, to ensure options are in the right state (#521)currentTime
, duration
and paused
bindings for media elements (#406)<:Window>
event handlers to access component state (#497)<select>
value correctly (#502)<select>
value binding when options are updated late (#476)namespace
option (#473)methods
(#425)if
statements with the same condition (#450)scroll
bindings are bidirectional (#404)bind:online
to window (#404)defer: true
now triggers callback after DOM is updated (#441)computed
property (#452)<select>
value attributes with objects (#423)assign
helper instead of Object.assign
for better performance and legacy compatibility (#431)<script>
tag causing infinite loop (#435){{true}}
, {{false}}
and {{null}}
(#424)<select>
value attributes correctly (#423)import root
(#430)css
property in compiler output (#409)<:Window>
meta tag with event listeners, and a handful of bindings (#371)addCss
etc) (#388){{class}}
(#383)<Widget :foo/>
is equivalent to <Widget foo='{{foo}}'/>
(#384)bind:group
for radio and checkbox inputs (#311, #312)component.observe
arguments (#369)component.on('teardown', ...)
to component.on('destroy', ...)
and add dev warning (#365)each
blocks (#356)format: 'eval'
and svelte.create
, to create components directly from source code (#345)'</script>'
string occurence breaking pages (#349)
incorrectly (#348)let
-> var
in addCss
block (#351)<script>
and <style>
tags to pass through without processing (#335)onrender
and onteardown
in favour of oncreate
and ondestroy
(#40)input
events (not change
) for all input elements other than checkbox
and radio
, and textareas (#309)svelte.parse
output (#302)<select>
elements with two-way binding correctly (#301)each
blocks (#290)each
blocks (#290)<option>
value correctly (#291)sources
and sourcesContent
are populated in sourcemaps, even if none of the original code is used (#295)outputFilename
option to populate file
and sources
sourcemap properties correctly (#295)onrender
, including when change initiator is a nested component (#263)<!doctype>
declarations (#255){{yield}}
bugs for components inside if
and each
blocks (#230, #231)<svg>
elements correctly (#233)svelte.VERSION
property to compileraddEventListener
, removeEventListener
, setAttribute
(#227)sharedPath
(#229)standalone: false
with shared: true
, or shared: 'custom/path/to/shared.js'
(#218)shared.js
in packageeach
blocks (#81)format
option (#196)options.onerror
namespace
declaration for SVG (etc) components (#147)this
or arguments
(#179)setAttribute()
for list
attributes, to preserve link to <datalist>
(#178)event
/this
in event handlers (#162)mount
from public API (#150)generate: 'ssr'
) (#159)helpers
(#163)xmlns
attributes correctly (#142)<style>
/<script>
tags rather than failing silently (#142)mount
(#91)onrender
hook at correct time for nested components (#103){{yield}}
(#112){{#each ...}}...{{else}}...{{/each}}
(#90)get()
without arguments returns entire state object (#73)if
blocks, especially with else
/elseif
chains (#28)else
/elseif
blocks (#49)Set style.cssText
rather than style
(#44)
setAttribute
with SVG elementsref
incorrectly (#24)onrender
hooks once component is in DOM (#18)devDependencies
readUntil
errors in parser<select>
bindingbind:foo
shorthandelse
and elseif
blocksfire
and on
methods此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。