Shopify / Shopify/shopify-app-template-react-router
Using middleware for authentication
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 197
- Forks
- 68
- Avg merge
- 4d 21h
- Merged PRs (30d)
- 4
Description
Hi !
One of the biggest imporvement of React Router 7 is the support for middlewares. Middlewares should allows moving the authenticate to a single middleware, hence removing the need to call authenticate on every loader. However it does not seem to be used in this template. Any reason why?
Thanks
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing how authenticate is called from each loader and compare that with React Router 7 middleware support. Determine whether this template can centralize authentication in middleware, then verify that protected routes retain the same behavior without individual loader calls.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- authentication
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100