Sure! To start, take a look in the following places:
-
This is where we return an error message on login if the user has not yet signed up: https://github.com/spoonjoy/redwoodjs-dbauth-oauth/blob/43f13835c1e9fd63a688e3c8c63aba5b74e3a405/api/src/OAuthHandler.ts#L1106
-
Right below it is where we kick off the sign up flow: redwoodjs-dbauth-oauth/api/src/OAuthHandler.ts at 43f13835c1e9fd63a688e3c8c63aba5b74e3a405 · spoonjoy/redwoodjs-dbauth-oauth · GitHub
So I would add an option to OAuthHandlerOptions called something like signupOnFailedLogin that calls that signup method instead of returning an error.
That said, if you’re focusing on building some type of app, I wouldn’t worry about details like this just yet — the difference it’ll make to any perspective users it not worth the effort.
However, if you’re just learning FSD and this interests you, then go for it!! I’m here to help ![]()