Login component export

  • nix.nz-1275001570118860841

    Marko

    7 months ago

    Hi there! I’ve created a component for logging users in using a standard email and password form, with Supabase as my backend auth. It works great in toddle, but when I export the component script and place it on my Webflow website, it doesn’t seem to work; error messages from the console below.

    I’m aiming to create my own solution instead of using Memberstack or Outseta so I can have more freedom in how users log in and interact with their profile data. All the authenticated components will be made in toddle. The website is already built in Webflow, and the client is keen to stay with it.
    1275087251382210570-
  • lucasg-1275113217596588103

    Lucas G

    7 months ago

    That's going to take some work/workarounds
  • A login form is easy to set up in toddle as it runs through toddle's servers and handles the cookies/tokens for us in the requests
  • I think you'll have to manage all of that if you want to put it elsewhere
  • Since you won't be able to proxy the call
  • nix.nz-1275216357725831178

    Marko

    7 months ago

    Damn, I figured that was the case. All good, I have an idea to get this sorted. Cheers!
  • sanedealer-1290735956776980534

    Edwin Paul

    5 months ago

    Hey, im facing a similar problem. How did you sort this out?
  • lucasg-1290743901451194490

    Lucas G

    5 months ago

    Either your login button on a external site redirects to your toddle app and they login there or you handle the session/cookies yourself
    🙌1
  • nix.nz-1290869985685667921

    Marko

    5 months ago

    Yep this is what I did, thanks!
  • sanedealer-1291009590103769179

    Edwin Paul

    5 months ago

    What worked for me was switching from session cookies to local storage.
  • lucasg-1291034905270292522

    Lucas G

    5 months ago

    That is not a secure approach at all so be mindful that there's no sensitive data behind your login
  • sanedealer-1291155396735533056

    Edwin Paul

    5 months ago

    Thanks for the heads-up!

Stop scrolling. Start building.

toddle is a visual web app builder that rivals custom code — but accessible to your entire team!

Try toddle — it's free!

© Copyright 2024 toddle. All rights reserved.