intelligent-worker-probe
Cache-Busting with solid.js
I have the same problem.
Everything you describe is a vite and not specific to solidjs. Its easier to search more info about that in vite in combination with react/vue.
My current try is saving the build/commit-number as a version and fetching it in the client from the server, comparing the stringss and reload/refresh the browser if they mismatch -> Implemented just today. I guess I'l have to test and see if it works / is enough.
My big solution (which I'm hesitant to implement) is uploading all build files to a cdn/s3 and just keeping all old assets around (<1-3 mb -> so a negligible amount of storage). Especially with a storage that supports deduplication, like backblaze b2.
19 replies
importing static assets (telling vinxi/vite about stuff other then png's)
I put all my static files in the public/ folder and reference them using absolut paths (folder = public/imgs/img.png, link = /imgs/img.png).
I wonder if it is better or worse vs using the static import feature from vite?
14 replies
SolidStart ver.1
Yarns 2.0+ and everyhting "pnp" has never worked for me (last try in 2023), especially with libraries like prisma, next or vite that rewrite the content in node_modules.
I do not know anyone who uses yarn 2.0+, only people who still use yarn 1.0 and did not bother to update (or tried an failed).
15 replies
createAsync vs createResource and how does Suspense work?
Design, usage and goals are discussed and presented in the RFC itself from 2023
https://github.com/solidjs/solid-router/discussions/306
41 replies
createAsync vs createResource and how does Suspense work?
I think much/some of this is documented in the solid-router main repo page
https://github.com/solidjs/solid-router?tab=readme-ov-file#data-apis
41 replies
SolidJS with Vite vs Solid Start
I solved the FOUC problem by using
Astro - and inlining script tags -> its very good documented
https://docs.astro.build/en/tutorial/6-islands/2/
7 replies
How Do I Update The createAsync() Signal?
maybe try: to wrap/extend your fetched data with hasError. So if hasError is true you can display the button to retry. I think caching is still a problem though, since the build-in caching mechanism does not know that an error has happened and caches it instead. So I guess you have to build your own caching mechanism?
33 replies
How to implement JWT authentication in SolidJS, without SolidStart?
You have to set the path "/" explicitely, or the default is a subpath that can't be accessed in other paths
https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies
9 replies