pull/2132/head
Richard Harris 7 years ago
parent db47847282
commit bf2c4e4680

@ -2,7 +2,7 @@
title: <svelte:body>
---
Similar to `<svelte:window>`, the `<svelte:body>` element allows you to listen for events that fire on `body`. This is useful with the `mouseenter` and `mouseleave` events, which don't fire on `window`.
Similar to `<svelte:window>`, the `<svelte:body>` element allows you to listen for events that fire on `document.body`. This is useful with the `mouseenter` and `mouseleave` events, which don't fire on `window`.
Add the `mouseenter` and `mouseleave` handlers to the `<svelte:body>` tag:

@ -147,7 +147,7 @@ Maybe lifecycle should go first, since we're using `onMount` in the `this` demo?
* [x] `<svelte:self>`
* [x] `<svelte:component>`
* [x] `<svelte:window>`
* [ ] `<svelte:body>`
* [x] `<svelte:body>`
* [ ] `<svelte:head>`

Loading…
Cancel
Save