When I click something like this:
function handleSetViewMode(viewMode: string) {
params.set('view', viewMode);
console.log('using router.push()');
router.push(`?${params}`);
}
A _rsc
param attaches to the URL:
assets?view=list&_rsc=clg3k
This produces a 500 error, and making the page refresh.
The weird thing is that this doesn’t happen with npm run dev
. Only after building the app and doing npm run start
.
What could be the issue, and how to solve it?
Also posted here.