Q: How to replace createSearchParams
In https://github.com/nanostores/router/blob/main/CHANGELOG.md?plain=1#L10 I read that
> * Removed `createSearchParams` in favor of `route.search` of normal router.
I have this Astro App which uses `export const $searchParams = createSearchParams()` to create a store that is stored in the URL. https://github.com/osmberlin/www.osm-verkehrswende.org/blob/main/src/components/BaseMap/store.ts#L23
How would I migrate that to route.search? I am not using the router in Astro, I am looking for something like an `atom`, but in the URL.
关闭于 2024-04-03 2 条评论