Update documentation/docs/97-best-practices/10-best-practices.md

Co-authored-by: ComputerGuy <63362464+Ocean-OS@users.noreply.github.com>
best-practices-doc
Rich Harris 2 days ago committed by GitHub
parent f03cc46cc3
commit b8e557afab
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -158,7 +158,7 @@ If a component uses CSS variables in his styling you can automatically pass them
## Stores
In Svelte 4 stores were THE way to allow interactivity outside of a `.svelte` file. In Svelte 5 that changed and you can now use a `.svelte.{ts|js}` file with universal reactivity.
In Svelte 4, stores were the only way to allow reactivity outside of a `.svelte` file. In Svelte 5, you can use runes in [`.svelte.{ts|js}`](/docs/svelte/svelte-js-files) files with universal reactivity.
When possible, prefer to use universal reactivity instead of stores. If you're writing a utility that may be used across multiple projects, keep in mind that some projects may still use stores, and try to make your utilities backwards-compatible.

Loading…
Cancel
Save