Comments (5)
I'm 100% human. Last moment they made some fixes related to base path and redirect and it has been fixed for action but it seems the issue is not fully fixed on components level.
from next.js.
Hey there! Ran into a bit of a snag with the redirect("/login") in your page component, huh? Especially when you're playing around with basePath in next.config.js, things can get a little tricky. I totally get the frustration when stuff just doesn't work as expected. But hey, you found a workaround by setting up a server action—that's awesome! It's all about those creative solutions.
If you're up for it, there's a video that might shed some light on the issue. Give it a watch right here: Loom Video. Sometimes, seeing it in action makes all the difference.
And if you're in the mood to dive deeper or tweak some more code, the entire codebase is waiting for you over at CodeSandbox. Who knows? You might just stumble upon something that clicks.
"Let's make the digital world smaller! Connect with me across the web on these social platforms and let's create, share, and inspire together." ✨🌐 #StayConnected
Solved 04
from next.js.
possibly related #59800
from next.js.
Hey there! Ran into a bit of a snag with the redirect("/login") in your page component, huh? Especially when you're playing around with basePath in next.config.js, things can get a little tricky. I totally get the frustration when stuff just doesn't work as expected. But hey, you found a workaround by setting up a server action—that's awesome! It's all about those creative solutions.
What are you talking about? You found a workaround, if you are not a bot, then sorry, this doesn't work for me, my workaround is to sacrifice the loading.tsx component.
from next.js.
I'm 100% human. Last moment they made some fixes related to base path and redirect and it has been fixed for action but it seems the issue is not fully fixed on components level.
Thank you for your input then, that's a valid workaround come to think of it, still hope it can be fixed on component level since it was very frustrating finding it.
from next.js.
Related Issues (20)
- Missing properties in Manifest type (`screenshots`)
- Docs: Clarify `React.cache()` usage in `generateMetadata()`
- `generateMetadata()` in root `layout.tsx` is called on every navigation
- Images not loading in NextJS 14 Headless WordPress demo fresh install HOT 1
- Optional catch-all route has highest priority when it should be last priority HOT 1
- Log drain verification is failing. HOT 1
- Can't load local fonts if using a custom _document.tsx HOT 1
- React Fragments Not Working the Same Way In Server Components HOT 2
- `next dev --turbo` errors when rendering MDX files HOT 1
- Server Environment variables accessible from Client HOT 2
- [regression] "'useContext' is not exported from 'react'" error message in latest canary, works fine in v14.1.0 HOT 5
- Cannot move directories in app directory Windows 10 HOT 2
- Module not found: Can't resolve '../build/Release/xxhash' HOT 2
- Dynamic Sitemap Causing Google to Not Recognize /Robots.txt Error
- App router : ISR always regenerates dynamic routes even when called with same params HOT 1
- Cannot use CommonJS packages in PNPM workspace HOT 1
- fastapi streaming response is not decoded in chunks with compression enabled
- Intercepting + Dynamic Routes, Jumping the page causes a forced refresh HOT 1
- `redirect()` inside Server Actions doesn't work with the same domain
- 404 error occurs after refreshing from intercepted parallel route. 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 next.js.