Skip to content

Commit 0891fa7

Browse files
authored
docs: Fix a typo and spelling in Svelte 5 breaking changes doc (#12517)
* Fix a typo in Svelte 5 breaking changes doc: “accessors” * Fix inconsistent spelling: “favour”
1 parent f402d01 commit 0891fa7

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sites/svelte-5-preview/src/routes/docs/content/03-appendix/02-breaking-changes.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import App from './App.svelte'
1818
export default app;
1919
```
2020

21-
`mount` and `hydrate` have the exact same API. The difference is that `hydrate` will pick up the Svelte's server-rendered HTML inside its target and hydrate it. Both return an object with the exports of the component and potentially property accessors (if compiled with `accesors: true`). They do not come with the `$on`, `$set` and `$destroy` methods you may know from the class component API. These are its replacements:
21+
`mount` and `hydrate` have the exact same API. The difference is that `hydrate` will pick up the Svelte's server-rendered HTML inside its target and hydrate it. Both return an object with the exports of the component and potentially property accessors (if compiled with `accessors: true`). They do not come with the `$on`, `$set` and `$destroy` methods you may know from the class component API. These are its replacements:
2222

2323
For `$on`, instead of listening to events, pass them via the `events` property on the options argument.
2424

@@ -99,7 +99,7 @@ In Svelte 4, rendering a component to a string also returned the CSS of all comp
9999

100100
### Component typing changes
101101

102-
The change from classes towards functions is also reflected in the typings: `SvelteComponent`, the base class from Svelte 4, is deprecated in favor of the new `Component` type which defines the function shape of a Svelte component. To manually define a component shape in a `d.ts` file:
102+
The change from classes towards functions is also reflected in the typings: `SvelteComponent`, the base class from Svelte 4, is deprecated in favour of the new `Component` type which defines the function shape of a Svelte component. To manually define a component shape in a `d.ts` file:
103103

104104
```ts
105105
import type { Component } from 'svelte';

0 commit comments

Comments
 (0)