https://discord.com/channels/603466164219281420/907932061669654548/1202007865028775937 I've started ...
i
https://discord.com/channels/603466164219281420/907932061669654548/1202007865028775937 I've started the migration from the Remix example to the Next.js app directory example. (At least for now.) And I think Remix does things way better. 😅 I wanted to suggest adding documentation on how to use the
ThirdPartyEmailPassword
option without using the Express middleware, and perhaps suggest exposing clear functions for it if they aren't yet available. (I assumed that they would be available since we now have things like
*withoutRequestResponse()
.) I've been approached multiple times on both my Remix and my SvelteKit examples regarding how to get
ThirdPartyEmailPassword
up and running. It seems to be the most common recipe (or one of the most common). And having a way to set things up clearly (without having to bring other SuperTokens packages into the mix) would likely be a big win. It might also alleviate some of the package management that SuperTokens has to deal with for various JS frameworks. I would look into it, but I unfortunately haven't had the time to scrutinize SuperTokens's internals like I did last time. 😅 I'm still looking for an opportunity. I'm only just now getting to the Next.js app dir example. (I know SuperTokens has one. This would just be one that would be more direct -- requiring less NPM packages and higher order functions.)
r
Hey @ITEnthusiasm you mean that we should add does for how to integrate with a custom framework, right?
i
Yeah, basically. If there's a way to do it without middleware or some kind of middleware wrapper, I think that would be helpful. So something more like https://github.com/ITenthusiasm/svelte-kit-supertokens/blob/main/src/hooks.server.ts for authentication checking and https://github.com/ITenthusiasm/svelte-kit-supertokens/blob/main/src/lib/server/utils/supertokens/index.ts for logging in/out users, refreshing their sessions, etc. In both of those files, people are able to leverage the functions that SuperTokens exposes to get the job done without having to rely on a pre-packaged request-handler of sorts (and without having to override the SuperTokens recipe methods as well). This would probably provide the most power.
r
yea, we do have a way to handle custom framework integrations. You can see how thats done in our rexmix example app! The docs for it, would be useful. However, don't have any specific timeline for now unfortunately.
i
As long as the team is aware, that's something. 😅 I just don't want the idea to go on missed/unaddressed. It would open up SuperTokens to more people who want to use the tool in their respective frameworks, and it would enable me to update my existing examples with those functions. I can scrutinize the Remix example and the code for
supertokens-node
again too when I find the time. I just don't have said time at the moment. 😬
r
Makes sense! Thank you! As always 🙂
2 Views