S
SolidJS11mo ago
sh1man

solidstart authorized example

can anyone share the solidstart code which has authorization and redirection of the user if he is not authorized
5 Replies
Birk Skyum
Birk Skyum11mo ago
Hi @sh1man , a bug has recently been discovered with the authjs integration, so there there is an ongoing effort make it work - you can follow it in here: https://discord.com/channels/722131463138705510/1203320729047801877/1204843854071595131 As soon as the middleware works, this PR with an auth example will become a good starting point. https://github.com/solidjs/solid-start/pull/1304
sh1man
sh1manOP11mo ago
Thank you
sh1man
sh1manOP11mo ago
@auth/solid-start | Auth.js
@auth/solid-start is currently experimental. The API will change in the future.
sh1man
sh1manOP11mo ago
Is this a good thing? She will work ?
Birk Skyum
Birk Skyum11mo ago
it's unfortunately not yet compatible with the latest version of solid start, and it's necessary to await a new version of this package (@solid-mediakit/auth) https://mediakit-taupe.vercel.app/auth/install. As I understand it, there is a bug in the solidstart middleware system, where it doesn't await the completion of each middleware (in case they have async functions) before going to the next.
Want results from more Discord servers?
Add your server