-
Notifications
You must be signed in to change notification settings - Fork 128
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for Deno #110
Comments
@iuioiua the Auth component needs to be client-side rendered as it's making a bunch of Ajax requests, so I think we need to put it into and island component. I tried putting it in an island, but then I'm getting this An error occured during route handling or page rendering.
TypeError: Cannot read properties of undefined (reading '__H')
at a (https://esm.sh/stable/[email protected]/deno/hooks.js:2:189)
at k (https://esm.sh/stable/[email protected]/deno/hooks.js:2:323)
at P (https://esm.sh/stable/[email protected]/deno/hooks.js:2:292)
at Object.ee (https://esm.sh/v106/@supabase/[email protected]/X-YS9yZWFjdDpwcmVhY3QvY29tcGF0CmQvcHJlYWN0QDEwLjEyLjA/deno/auth-ui-react.js:2:41388)
at https://esm.sh/v99/[email protected]/X-ZS8q/deno/preact-render-to-string.js:12:1626
at E (https://esm.sh/v99/[email protected]/X-ZS8q/deno/preact-render-to-string.js:12:1653)
at E (https://esm.sh/v99/[email protected]/X-ZS8q/deno/preact-render-to-string.js:12:918)
at E (https://esm.sh/v99/[email protected]/X-ZS8q/deno/preact-render-to-string.js:12:1729)
at E (https://esm.sh/v99/[email protected]/X-ZS8q/deno/preact-render-to-string.js:12:2689)
at E (https://esm.sh/v99/[email protected]/X-ZS8q/deno/preact-render-to-string.js:12:2578) Any ideas how to resolve that? I think it's some react <> preact (in)compatability issues. |
I've managed to get further. Try:
I'll try get my code uploaded soon. |
@thorwebdev, I'll create a simplified dummy repo to reproduce this issue. |
@thorwebdev, I've created a minimal reproduction of this issue so we can play around with this issue. Hopefully, we'll get the Supabase Auth UI working with Fresh. Check it out here: https://github.com/iuioiua/fresh-supabase-auth-ui |
@iuioiua when running your repo https://github.com/iuioiua/fresh-supabase-auth-ui I don't get anything rendered to the screen, but I'm afraid I have no idea why that is. Probably would need someone with deep Fresh <> React <> Preact experiece to dig into this. I think for the time being you'd be best off using the Auth approach employed here: https://github.com/thorwebdev/everydaylytics It uses Fresh's way of submitting forms (whereas the Auth UI uses Ajax requests), as well as cookies to store sessions (rather than Auth UI using localStorage), so I think for Fresh, the current Auth UI approach isn't the best fit. You can find more details on the Auth approach, including Oauth here: https://github.com/thorwebdev/everydaylytics#auth-approach |
I see. Thanks for looking into it, either way, @thorwebdev! Very much appreciated. |
I'll keep this open to track Deno support for the future 👍 |
Bug report
Describe the bug
Auth
component returns nothing in Deno. I'm unsure whether this is an issue with Deno, this package, or ESM.To Reproduce
Steps to reproduce the behavior, please provide code snippets or a repository:
Expected behavior
The Auth UI should be rendered as seen in the thumbnail of the video in the documentation.
Screenshots
System information
supabase-js
: 2.7.0auth-ui-react
: 0.2.6fresh
: 1.1.3Additional context
I have not yet seen any examples of the Auth UI package being used in Deno, so I wonder whether this is even possible with the current code base and Deno runtime. Am I doing something wrong?
The text was updated successfully, but these errors were encountered: