React Native/Expo support
Hi, thanks for this awesome solution. Is this only limited to nextjs app router or can it be used outside of nextjs. I've an expo app where I want to use the same auth as the website one so can I use this for both website and app?
Hey by design the core of Stack should work in mobile app environment. You just need to initialise StackClientApp instead of StackServerApp and only pass in the client keys, then all the client side functionalities should be on that object.
However, there are a few things that we still need to do to make it fully work with RN/Expo:
- Token storage system for mobile (currently stored in cookies on web)
- OAuth redirect URL/browser opening for mobile (it is slightly different there)
I tried once to set it up in RN/Expo but I encountered some compiling/dependency issues. I will check again later and see if there are easy fixes to it.
I can probably help to implement and test this feature if you guide me on how can I proceed and what are the things we'll need to do in stack
@imranbarbhuiya are you still working on this one
Happy to re-open if any one in the community wants to make Stack work on RN
Is there a working demo of this using React Native/Expo? Or has anyone successfully run through the process?
@fomalhautb I am using stack for my project in react native, if everything goes well I would like create the react native SDK. Will comment here if and when I start working on it. Really like what you guys are doing <3