Comments (5)
Thanks for reporting this (and the other issues you've reported!) 🙏
It's mutual, thanks for the fast response time! It's a pleasure contributing to an open-source project that is so fast to react (I really dislike contributing to open-source projects that take ages to get back).
from redwood.
Hey @suzdalnitski, I'm not totally sure what the issue you're facing is, but there's a detail wrong in your reproduction that's probably leading to problems.
If you want to add a new route to your web app that's accessible at http://localhost:8910/auth
, you'll have to 1) add a new <Route>
to the web/src/Routes.tsx
file and 2) make a new page in web/src/pages
(the page generator does both those things for you: yarn rw g page auth
).
It looks like you've added the file to web/src/
; the router won't know to pick it up there. Let me know what I'm missing though if that's not the problem!
from redwood.
Hey @jtoar, I was actually setting up authentication with Supertokens. I've ran yarn rw setup auth supertokens
. It has generated auth.tsx
, and has updated Routes.tsx
.
You're correct, there's no auth
page, because Supertokens doesn't come with a Redwood Page.
Routes has this instead:
const Routes = () => {
if (canHandleRoute(PreBuiltUI)) {
return getRoutingComponent(PreBuiltUI)
}
return (
<Router useAuth={useAuth}>
<Set wrap={AppLayout}>
<Route path="/" page={HomePage} name="home" />
</Set>
<Route notfound page={NotFoundPage} />
</Router>
)
}
from redwood.
@suzdalnitski Thanks for reporting this (and the other issues you've reported!) 🙏
Do you see this issue with both yarn rw dev
and yarn rw build && yarn rw serve
?
Do you think you could provide a step-by-step reproduction? Preferably without involving supertokens if possible.
from redwood.
I've pushed a repo that reproduces the issue: https://github.com/suzdalnitski/redwood-auth-bug
The only things I've done were:
yarn create redwood-app test-app
yarn rw setup auth supertokens
yarn rw dev
Then I opened http://localhost:8910/auth
.
from redwood.
Related Issues (20)
- [Bug?]: Developer UX for large applications is poor HOT 3
- feat: Setup GraphQL Trusted Documents with a setup command HOT 2
- [Docs]: how functions work in a PaaS environments like Render.com HOT 4
- [Docs]: Chapter 5 of the Tutorial uses an old format of Storybook HOT 1
- [Bug?]: `yarn rw test` causes antivirus program to warn me about access to folder on Mac OS HOT 14
- [Docs]: <Set private> is deprecated, used within Router docs HOT 1
- [Docs]: Confusion regarding the SUPERTOKENS_* env variables in generated code HOT 10
- [Bug?]: Generators Cannot read properties of undefined (reading 'startsWith') HOT 5
- [Bug?]: Invalid SDL generated with certain Prisma models that lack editable fields HOT 2
- [Bug?]: Prisma Model with Bytes field fails SDL generation in Service Test template HOT 4
- [Bug]: Cell generation does not support the Custom Prisma Id Field that Scaffolding Supports
- [Bug?]: FastifyError [Error]: The decorator 'urlData' has already been added! HOT 2
- [Docs]: Firebase setup
- [Docs]: Authentication and routes HOT 1
- Change auth impersonation in Studio to not use Request body HOT 1
- Error in Redwood Studio HOT 6
- [Bug]: yarn create redwood-app ... stopped by ERR_IMPORT_ASSERTION_TYPE_MISSING HOT 4
- [Bug?]: url search parameter is erased if originated from outside the app (via redirection) HOT 4
- [Bug?]: the teardown in jest.setup is attempting to delete data from views HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from redwood.