0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2025-01-20 22:12:38 -05:00

fix: syntax error in changelog (#11869)

This commit is contained in:
Erika 2024-08-29 13:48:51 +02:00 committed by GitHub
parent a85a184d9f
commit 9da5b3dab2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -6,7 +6,7 @@ Adds a new object `swapFunctions` to expose the necessary utility functions on `
The example below uses these functions to replace Astro's built-in default `swap` function with one that only swaps the `<main>` part of the page: The example below uses these functions to replace Astro's built-in default `swap` function with one that only swaps the `<main>` part of the page:
```astro ```html
<script> <script>
import { swapFunctions } from 'astro:transitions/client'; import { swapFunctions } from 'astro:transitions/client';
@ -26,7 +26,7 @@ function swapMainOnly(doc: Document) {
} }
restoreFocusFunction(); restoreFocusFunction();
}; };
<script> </script>
``` ```
See the [view transitions guide](https://docs.astro.build/en/guides/view-transitions/#astrobefore-swap) for more information about hooking into the `astro:before-swap` lifecycle event and adding a custom swap implementation. See the [view transitions guide](https://docs.astro.build/en/guides/view-transitions/#astrobefore-swap) for more information about hooking into the `astro:before-swap` lifecycle event and adding a custom swap implementation.