I have a standalone Django Rest API that has its own Sign Up and Login process and all that. I'm trying to make it so that when a new user is created in wasp and added to the prisma database, a post request is made to my Django API's User Create endpoint, so that I can create a user there as well. This will let me make authenticated requests to the API for other endpoints and purposes.
However, I can't figure out how and where to add my code for the Django request. I could potentially modify the wasp LoginandSignupForm itself, but I'd rather not modify that code.
If I were to just create an action to make this request, how would I incorporate that into the signup page, since the Signup Form component can't be modified directly in the SignupPage.tsx.
import { SignupForm } from 'wasp/client/auth';import { Link } from 'react-router-dom';import { AuthWrapper } from './authWrapper';export function Signup() { return ( <AuthWrapper> <SignupForm /> <br /> <span className='text-sm font-medium text-gray-900'> I already have an account ( <Link to='/login' className='underline'> go to login </Link> ). </span> <br /> </AuthWrapper> );}
import { SignupForm } from 'wasp/client/auth';import { Link } from 'react-router-dom';import { AuthWrapper } from './authWrapper';export function Signup() { return ( <AuthWrapper> <SignupForm /> <br /> <span className='text-sm font-medium text-gray-900'> I already have an account ( <Link to='/login' className='underline'> go to login </Link> ). </span> <br /> </AuthWrapper> );}
I'm just completely lost on this and have spent around 8 hours trying to figure this out. If anyone has any suggestions that would be really helpful.
Recent Announcements
Continue the conversation
Join the Discord to ask follow-up questions and connect with the community
W
Wasp
Rails-like framework for React, Node.js and Prisma. Build your app in a day and deploy it with a single CLI command.