Zum Inhalt springen

Svelte Release Notes

Einträge
181
Quellen
2
Zuletzt aktualisiert

Folge Svelte, um die Release Notes in deinen Feed zu holen.

Svelte

Neuerungen in Svelte im Dezember 2023

Auf dem Svelte Summit Fall 2023 wurden Svelte DevTools, Bildoptimierung und eine Vorschau von Svelte 5.0 vorgestellt.

Svelte Summit Fall 2023 was epic! Featuring talks from across the ecosystem and the launches from the core team of new Svelte Dev Tools, image optimization, and a preview version of Svelte 5.0! The whole talk can be found here (timestamps below):

  • 0:00 Hype music!
  • 18:20 Exploring Svelte DevTools - Ignatius B (4 minutes)
  • 25:27 How does SvelteKit fare as a SPA Framework - Henry Lie (25 minutes)
  • 53:00 enhanced:img - Ben McCann (6 minutes)
  • 1:03:44 inlang-paraglide JS for SvelteKit i18n - Samuel Stroschein (10 minutes)
  • 1:17:32 How Svelte & GraphQL plays well together - Jean-Yves Couet (31 minutes)
  • 1:53:10 svelte-ecosystem-ci - Dominik G (10 minutes)
  • 2:23:06 Svelte for Creative Development - Steven Stavrakis (10 minutes)
  • 2:35:33 Translating the docs - Romain I’Ourson (11 minutes)
  • 2:49:48 ENHANCE! - Paolo Ricciuti (25 minutes) …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Neuerungen in Svelte und SvelteKit im November 2023

Svelte 4.2.2 behebt element-spezifische Probleme, die Sprachetools verbessern Block-Folding und Routenparameter-Typen werden in SvelteKit 1.26 aus Matcher-Guards abgeleitet.

Mark your calendars! Svelte Summit Fall is on November 11th. Join us on YouTube and in the Discord for hours of Svelte-focused fun 🎥

Every month, maintainers within the Svelte ecosystem fix bugs, improve performance and bring new features to Svelte, SvelteKit and the tooling around them. This month’s releases brings an improved developer experience with better block folding, inferred types and configuration for use:enhance.

Let’s take a closer look 👀...

What’s new in Svelte & Language Tools

  • Svelte 4.2.2 cleans up a few element-specific features (Release Notes)
  • Extensions 107.12.0 improves block folding for functions, if statements and more (Release Notes, PR)

What’s new in SvelteKit

  • Route parameter types will now be inferred from the applicable matcher’s guard check (kit@1.26.0, Docs, #10755) …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Neuerungen in Svelte und SvelteKit im Oktober 2023

Svelte 4.2.1 enthält Fixes für HTML-, CSS- und Sourcemap-Kompilierung, die Sprachwerkzeuge verbessern Komponentenreferenzen und die auto-types-Fallback-Behandlung.

Svelte 5 isn’t out yet (you can, however, preview it now), but that doesn’t mean we don’t get a sneak peek! Most notably are Runes - a simpler way to manage reactive variables in Svelte code. There’s lots of links the showcase section for deeper dives on all things Runes, but let’s talk about what else been released this month...

What’s new in Svelte & Language Tools

What’s new in SvelteKit …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

SvelteKit nimmt am Hacktoberfest 2023 teil

SvelteKit beteiligt sich am Hacktoberfest 2023; registrierte Entwickler können durch Pull-Requests zu SvelteKit am Event teilnehmen.

Sveltekit 🧡 Hacktoberfest

We’re excited to announce SvelteKit’s participation in this year’s Hacktoberfest! Hacktoberfest is a global event that takes place every October, during which developers are encouraged to contribute to open-source projects like SvelteKit. The goal is to foster a vibrant open-source community, celebrate shared knowledge, and make the world of coding more accessible to all. You can find other participating repositories by searching the hacktoberfest topic on github.

Getting Started

The first step is to register for Hacktoberfest. Once you’ve registered, any PRs submitted to Sveltekit will count towards your participation in the event!

Contributing

If you need inspiration when looking for an issue to fix, check out the low hanging fruit, contributions-welcome, ready to implement, or documentation tags. …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Einführung von Runes für Svelte 5

Svelte 5 führt runes ein, die universelle, feingranulare Reaktivität in JavaScript ermöglichen und für fast alle bestehende Komponenten kompatibel sind.

In 2019, Svelte 3 turned JavaScript into a reactive language. Svelte is a web UI framework that uses a compiler to turn declarative component code like this...

App

<script>
	let count = 0;

	function increment() {
		count += 1;
	}
</script>

<button on:click={increment}>
	clicks: {count}
</button>
<script lang="ts">
	let count = 0;

	function increment() {
		count += 1;
	}
</script>

<button on:click={increment}>
	clicks: {count}
</button>

...into tightly optimized JavaScript that updates the document when state like count changes. Because the compiler can ‘see’ where count is referenced, the generated code is highly efficient, and because we’re hijacking syntax like let and = instead of using cumbersome APIs, you can write less code.

A common piece of feedback we get is ‘I wish I could write all my JavaScript like this’. When you’re used to things inside components magically updating, going back to boring old procedural code feels like going from colour to black-and-white.

Svelte 5 changes all that with runes, which unlock universal, fine-grained reactivity.

Introducing runes

Before we begin

Even though we’re changing how things work under the hood, Svelte 5 should be a drop-in replacement for almost everyone. The new features are opt-in — your existing components will continue to work. …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Neuerungen in Svelte und SvelteKit im September 2023

Svelte 4.2.0 verschiebt svelteHTML in den Kern, SvelteKit 1.23 akzeptiert URL in redirect und warnt bei falsch geschriebenen Routen, 1.24 führt onNavigate für View Transitions ein.

Happy September y’all! With all the sneak peeks at what’s coming soon in Svelte 5, we thought it’d be best to look back at the last month to see what’s shipped and what the community is building with Svelte.

Before we jump in, a warm welcome to the new Svelte Ambassadors: @cainux and @grischaerbe! Welcome to the crew ⛴️

What’s new in Svelte & Language Tools

  • svelteHTML has moved from language-tools into Svelte core so that svelte/element types will now load correctly (4.2.0 in Svelte, 107.10.0 in Language Tools)

What’s new in SvelteKit

  • URL is now accepted in the redirect function (1.23.0, Docs, #10570)
  • Mistyped route filenames will now throw a warning (1.23.0, #10558)
  • The new onNavigate lifecycle function enables view transitions - Check out the blog post for more info (1.24.0, Docs, #9605) …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

View Transitions in SvelteKit 1.24 aktivieren

Der neue onNavigate-Hook in SvelteKit 1.24 erleichtert die Integration des View-Transitions-API in Navigationsabläufe.

The view transitions API has been sweeping the web development world lately, and for good reason. It streamlines the process of animating between two page states, which is especially useful for page transitions.

However, until now, you couldn’t easily use this API in a SvelteKit app, since it was difficult to slot into the right place in the navigation lifecycle. SvelteKit 1.24 brought a new onNavigate lifecycle hook to make view transitions integration much easier – let’s dive in.

How view transitions work

You can trigger a view transition by calling document.startViewTransition and passing a callback that updates the DOM somehow. For our purposes today, SvelteKit will update the DOM as the user navigates. Once the callback finishes, the browser will transition to the new page state — by default, it does a crossfade between the old and the new states.

documentvar document: Documentwindow.document returns a reference to the document contained in the window.
MDN Reference
.startViewTransition(method) Document.startViewTransition(callbackOptions?: ViewTransitionUpdateCallback | StartViewTransitionOptions): ViewTransitionThe startViewTransition() method of the Document interface starts a new same-document (SPA) view transition and returns a ViewTransition object to represent it.
MDN Reference
(async () => { …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Neuerungen in Svelte und SvelteKit im August 2023

Svelte 4.1.0 erlaubt weitere Anpassungen am Custom-Element-Wrapper, SvelteKit 1.22.0 bietet die HEAD-Server-Methode und das Caching von Vary-Antworten.

Some sweet new features have dropped in both Svelte and SvelteKit, this month. It’s also great to see how many products and side projects have launched using Svelte as their core technology!

More on all that down below...

What’s new in Svelte & Language Tools

There’s been a bunch of minor bugfixes since the Svelte 4 release. You can find them in the CHANGELOG.

The 4.1.0 release added the ability to further customize the custom element class that wraps the underlying Svelte component. Check out the Custom Elements API docs or the PR for more info!

In addition to supporting SvelteKit’s new HEAD server method, Svelte’s language tools now support Prettier v3 (extensions-107.9.0) and workspace trust settings are now used to support all settings in workspace (extensions-107.8.0).

What’s new in SvelteKit

  • The HEAD server method is now available in API routes (1.22.0, Docs, #9753)
  • Responses with Vary headers are now cached, too (except for Vary: *) (1.22.0, Docs, #9993) …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Neuerungen in Svelte und SvelteKit im Juli 2023

Svelte 4.0 wurde veröffentlicht, SvelteKit 1.21.0 führt das neue event.isSubRequest-Boolean ein.

Svelte 4 is out and folks have been building! There’s a bunch of new showcases, libraries and tutorials to share. So let’s get right into it...

What’s new in Svelte

The big news this month was the release of Svelte 4.0! You can read all about it in the Announcing Svelte 4 post. From performance fixes and developer experience improvements to a brand new site, docs and tutorial... this new release sets the stage for Svelte 5 with minimal breaking changes.

If you’re already on Node.js 16, it’s possible you won’t see any breaking changes in your project. But be sure to read the migration guide for all the details.

For a full list of all the changes to the Svelte compiler, including unreleased changes, check out the CHANGELOG.

What’s new in SvelteKit

This month there were lots of awesome bug fixes, so be sure to upgrade to the latest version! There are also a few new features to mention:

  • The new event.isSubRequest boolean indicates whether this is a same-origin fetch request to one of the app’s own APIs during a server request (1.21.0, Docs, #10170) …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Neue Website mit mehrseitiger Doku

Die svelte.dev-Website wurde komplett überarbeitet: Die Doku ist in mehrere Seiten aufgeteilt, alle Module sind in der Seitenleiste aufgeführt, und alte Links werden automatisch umgeleitet; zusätzlich gibt es eine neue Suche.

When the initial version of Svelte v3 was released four years ago, it included the single-page documentation that folks have been familiar with. That documentation structure had stayed the same as Svelte’s API surface increased steadily and more details were added. As a result, the single page got larger and larger to the point where it was becoming difficult to find things. The community had been asking for a revamp, and now it’s here!

Meet the new svelte.dev — a complete overhaul of the old website.

Multi-page docs

The table of contents had grown to be quite large and you had to scroll across half a dozen screens to see the whole thing. We heard you! The docs are all split up into multiple pages now and all pages list their sections in the righthand sidebar.

All modules exposed by Svelte are also listed in the sidebar under the Runtime section:

  • svelte
  • svelte/store
  • svelte/motion
  • svelte/transition
  • svelte/animate
  • svelte/easing
  • svelte/action

svelte/compiler is under Compiler and API section

We’ve also taken extra care to ensure that all the links from the old website will be redirected to the correct new page.

Search …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Stable Release von Svelte 4 angekündigt

Svelte 4 ist als stabile Version erschienen und bietet kleinere und schnellere Hydration-Code sowie angehobene Mindestanforderungen.

After months in the making, we’re excited to announce the stable release of Svelte 4.

Time flies - Svelte 3 was released more than four years ago! In JavaScript-framework-time, that’s eons. Svelte’s freshness has persisted throughout, but Node.js and browser APIs have evolved during that time and today we’re updating Svelte to take advantage of some of these improvements. Svelte 4 is mainly a maintenance release, bumping minimum version requirements and tightening up the design in specific areas. It sets the stage for the next generation of Svelte to be released as Svelte 5 - we think you’ll love it.

If you haven’t tried Svelte yet, take it for a spin in our interactive tutorial, on StackBlitz, or locally with npm create svelte@latest. Svelte lets you easily put together web UIs leveraging the power of HTML, CSS, JS, and the Svelte compiler. Watch Svelte Radio Live to learn more about this release.

What’s new

Performance

This release results in smaller and faster hydration code. To see the impact, SvelteKit users can see their compiled output shrink in size by examining the .svelte-kit/output/client/_app/immutable/nodes folder. For example, on kit.svelte.dev the JS generated across the whole site was reduced in size by 12.7% (126.3 kB to 110.2 kB). …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Neuerungen in Svelte und SvelteKit im Juni 2023

Svelte 4.0.0-next.0 und Svelte 3.59.0 wurden veröffentlicht, mit korrektem Handling von Spread-Operatoren bei Array-Umstrukturierung.

Welcome to June everyone and congrats to our SvelteHack winners, across all the categories! If you missed it, these winners were announced at Svelte Summit on May 6th 🎉

The entire playlist of the summit, including all the talks broken up in to separate videos, can be found on the Svelte Society YouTube channel. So check it out, if you haven’t already.

Lots to cover in this month’s newsletter, including a lot of improvements to both Svelte and Kit...

What’s new in Svelte

Svelte 4.0.0-next.0, the first pre-release version of Svelte 4.0 is out! An explanation of the changes, improvements and goals of this release can be found in the Releases page on GitHub. Check it out to get an early sneak peek of the future of Svelte. It also includes a migration guide, for those interested in the minimal amount of breaking changes and deprecations.

Svelte 3.59.0 is also out, with a ton of new features:

  • Restructuring arrays with the spread operator (...) is now handled correctly (3.59.0, #8552, #8554) …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Neuerungen in Svelte im Mai 2023

Svelte 3.58.0 unterstützt CSS-@container-Queries, bind:innerText für contenteditable und neue Accessibility-Warnungen.

Before we dive into the updates, there’s a few announcements worth mentioning at the top:

New Svelte Ambassadors

Regular features of this newsletter and all-around great content creators for Svelte JoyOfCode and HuntaByte have been appointed as Svelte Ambassadors. Ambassadors are people who are well known for their helpfulness and contributions and for upholding Svelte’s reputation as a friendly, welcoming community, and we’re deeply grateful for their involvement!

SvelteHack winners will be announced May 6th

In a just a few days, we’ll find out who won SvelteHack - the Svelte Hackathon that took place between February 17th and April 17th. Tune in to Svelte Summit on May 6th to see if your favorite project was chosen 👀

Lots of submissions to the hackathon are featured in this month’s showcase... but first, let’s see what’s new!

What’s new in Svelte

  • style blocks now support CSS @container queries (3.58.0)
  • bind:innerText is now available for contenteditable elements (3.58.0)
  • A new accessability warning, a11y-interactive-supports-focus will now warn when interactive elements are not focusable (3.58.0) …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Neuerungen in Svelte im April 2023

Svelte 3.56.0 fügt den |stopImmediatePropagation-Event-Modifier und den axis-Parameter für slide-Transitionen hinzu.

Happy April, everyone! This month, we’re covering all the new features in the Svelte compiler, some quality-of-life improvements in SvelteKit and a huge showcase (like always).

In core team news, Dominic Gannaway has joined Vercel to work on Svelte full-time! Dominic is a world-class expert on wringing performance out of javascript engines, on the DOM, on reactivity, on accessibility, and more! You might know him as the creator of the Inferno UI framework or Lexical, Meta’s WYSIWYG editor. It’ll be great to see his talents at work across the Svelte ecosystem 🌱

Don’t forget! Svelte Summit Spring, Svelte’s 6th virtual conference, will be happening on May 6th. Also, there’s just two weeks left until the end of SvelteHack... It’s a great opportunity to share your creations with the community and maybe even earn a prize!

Now let’s jump into this month’s changes...

What’s new in Svelte

  • A bunch of new features are now available as of 3.56.0!
    • Add |stopImmediatePropagation event modifier for on:eventname (#5085, Docs)
    • Add axis parameter to slide transition (#6182, Docs) …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Typsicherheit ohne Aufwand

Mit der neuesten Svelte-Erweiterung werden load-Funktionen und data-Props automatisch typisiert, ohne manuelle Annotationen.

By sprinkling type annotations into your SvelteKit apps, you can get full type safety across the network — the data in your page has a type that’s inferred from the return values of the load functions that generated that data, without you having to explicitly declare anything. It’s one of those things that you come to wonder how you ever lived without.

But what if we didn’t even need the annotations? Since load and data are part of the framework, can’t the framework type them for us? This is, after all, what computers are for — doing the boring bits so we can focus on the creative stuff.

As of today, yes: it can.

If you’re using VSCode, just upgrade the Svelte extension to the latest version, and you’ll never have to annotate your load functions or data props again. Extensions for other editors can also use this feature, as long as they support the Language Server Protocol and TypeScript plugins. It even works with the latest version of our CLI diagnostics tool svelte-check!

Before we dive in, let’s recap how type safety works in SvelteKit.

Generated types

In SvelteKit, you get the data for a page in a load function. You could type the event by using ServerLoadEvent from @sveltejs/kit:

src/routes/blog/[slug]/+page.server

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Neuerungen in SvelteKit im März 2023

SvelteKit 1.4.0 bis 1.6.0 bringt $app/paths im Test, Routen-Konfiguration, Snapshots und OPTIONS-Servermethode.

March is coming in hot with a number of essential features having been added to SvelteKit following its 1.0 launch. Check out last week’s blog post for more details.

Svelte Society also launched SvelteHack last month with over $12,000 in prizes - calling all Svelte developers, new and old, to make something awesome before the April 17th deadline!

And, if you haven’t heard already, there’s going to be another Svelte Summit! Head over to SvelteSummit.com and sign up for the newsletter to get updates about the next event 📬

Now let’s jump into this month’s changes...

What’s new in SvelteKit

  • $app/paths can now be used without an app - making things like component testing with Vitest, using Storybook, etc. easier (1.4.0, #8838)
  • Adapters can now be configured at the route level (1.5.0, Docs, #8740)
  • The new snapshot mechanism preserves ephemeral DOM state even after navigation and page reloads (1.5.0,Docs, #8710)
  • OPTIONS are now available within the server method (1.6.0, Docs, #8731) …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Streaming, Snapshots und weitere neue Funktionen seit SvelteKit 1.0

SvelteKit 1.8 ermöglicht Streaming nicht-essentieller Daten aus load-Funktionen und das Rendern der Seite vor dem Abschluss.

The Svelte team has been hard at work since the release of SvelteKit 1.0. Let’s talk about some of the major new features that have shipped since launch: streaming non-essential data, snapshots, and route-level config.

Stream non-essential data in load functions

SvelteKit uses load functions to retrieve data for a given route. When navigating between pages, it first fetches the data, and then renders the page with the result. This could be a problem if some of the data for the page takes longer to load than others, especially if the data isn’t essential – the user won’t see any part of the new page until all the data is ready.

There were ways to work around this. In particular, you could fetch the slow data in the component itself, so it first renders with the data from load and then starts fetching the slow data. But this was not ideal: the data is even more delayed since you don’t start fetching until the client renders, and you’re also having to break SvelteKit’s load convention.

Now, in SvelteKit 1.8, we have a new solution: you can return a nested promise from a server load function, and SvelteKit will start rendering the page before it resolves. Once it completes, the result will be streamed to the page. …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Neuerungen in Svelte und SvelteKit im Februar 2023

SvelteKit erhält Verbesserungen bei der Basis-Pfad-Unterstützung für Remote-Entwicklungsumgebungen, automatische Einbindung des Submit-Wertes sowie neue Fehler- und Warnmeldungen im Entwicklungsmodus.

Since last month, we’ve seen a couple of minor versions across Svelte and SvelteKit, a bunch of educational content to support the 1.0 release, as well as the State of JS survey results...

Svelte, once again, increased in satisfaction and interest, so thanks to everyone who voted!

Let’s dive into the updates...

What’s new in SvelteKit

Work in the Svelte ecosystem this month has been focused on SvelteKit bug fixes and addressing feedback from the 1.0 launch. One of the more awaited bug fixes to SvelteKit’s base path support landed, which means that you can now create SvelteKit projects on remote development environments. There have been several new releases with these fixes as well as a handful of new features such as:

  • The submitter’s value will now be included automatically when progressively enhancing

    (1.0.3, #8273)

  • Added an error in dev mode if global fetch is used with relative URL (1.0.8, #8370)

  • A warning will now indicated that hydration may break if comments are removed from HTML (1.0.11, #8423) …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

Neuerungen in Svelte und SvelteKit im Januar 2023

SvelteKit 1.0 ist veröffentlicht, mit verbesserter Storybook- und Histoire-Unterstützung, vitePreprocess als Standard und einigen Breaking Changes bei Exports und URLs.

It’s been just two weeks since the release of SvelteKit 1.0! If you haven’t yet, check out the livestream, new website and tutorial to learn all the features of SvelteKit step-by-step.

Let’s dive into the details...

What’s new in SvelteKit

  • @sveltejs/kit 1.0 is out! All future releases will follow semver and changes will be listed as major/minor/patch in the CHANGELOG.
  • Improved support for Storybook and Histoire (#7990). Work is ongoing to fully support those tools (storybook#20239).
  • vitePreprocess is now the default preprocessor. Please see the docs for differences between vitePreprocess and svelte-preprocess (#8036).

Breaking changes:

  • Unknown exports (except when starting with an underscore) are no longer allowed from +(layout|page)(.server)?.js and +server.js files (#7878)
  • __data.json is now stripped from URL (#7979) …

Originalquelle(öffnet in neuem Tab)Problem melden

Svelte

SvelteKit 1.0 ist da

SvelteKit hat nach zwei Jahren Entwicklung Version 1.0 erreicht und ist ab sofort die empfohlene Methode zum Erstellen von Svelte-Apps jeder Größe.

After two years in development, SvelteKit has finally reached 1.0. As of today, it’s the recommended way to build Svelte apps of all shapes and sizes.

We’re so excited to share this release with you. It’s the culmination of thousands of hours of work, both from the Svelte core team and the wider community, and we think it’s the most enjoyable way to build production-grade websites, whether you’re a solo developer working on a small project or part of a large team.

To get started, run npm create svelte@latest, and visit the docs and (experimental!) interactive tutorial.

Svelte Radio Live: the Christmas special

What is SvelteKit?

SvelteKit is a framework for building web applications on top of Svelte, a UI component framework that developers love for its performance and ease of use.

If you’ve used component frameworks like Svelte, you’ll know that they make it much easier to build user interfaces than working with the DOM directly. But they leave a lot of questions unanswered:

  • How do I structure my source code?
  • How do I add server-side rendering?
  • How do I add routing that works on the server and in the browser? …

Originalquelle(öffnet in neuem Tab)Problem melden