Build a mobile popover menu with Svelte & OpenProps
Ғылым және технология
In this video, I'll discuss how to use the new Popover API and use Svelte & OpenProps to build a animated mobile menu.
Source Code: github.com/joshnuss/open-prop...
Links:
- Popover API: developer.mozilla.org/en-US/d...
- OpenProps: open-props.style
Пікірлер: 9
Really like how Svelte leverage the platform with a minimal impact on the bundle size. Thanks for sharing!
Built these plenty of times but so nice to see how someone else builds it, picked up a few things. Enjoyed the video Josh, thank you!!!!
Helpful, thanks!
Super simple explanation Josh! Thanks for the content
@josh_nussbaum
23 күн бұрын
Thanks Scott! 🙇 Was just reading your piece about patching, the newsletter is great 🙌
Great tricks. Thank you Josh.
@josh_nussbaum
22 күн бұрын
Thanks Sinan! 🙏
What's the best way to close the popover when clicking on a ? Looking for good a11y as well as the menu to close once a link is clicked.
@josh_nussbaum
23 күн бұрын
A few ways to do that in an SPA Handle on:click on links (without doing a preventDefault) and call popover.hidePopover() Another way, with SvelteKit, is to handle beforeNavigate and call popover.hidePopover()