Relative Content

Tag Archive for next.js13

Problem with permanentRedirect Next.js App router

I use an app router and on each pages, I add
export const dynamic = 'force-static';
I test even without this line and also I have that same case.
The URL page I paste to https://httpstatus.io/ should be redirected to a new page with status 308 -> 200.
Unfortunately, on the first time I get 308 and then 200, but each next time I get only 308. Why?
From API I get information about redirect and I use
permanentRedirect(redirectUrl, RedirectType['push']);

Error: [render-resolver] “onLoad” filter is not a valid Go regular expression (on executing npm run dev)

I’m encountering an error when trying to build my project using esbuild. The error message is as follows: Error: [render-resolver] “onLoad” filter is not a valid Go regular expression: “C:UsersHPDesktopCalanderManagementSystemshedularemailtrialreact-email-starteremailsvercel-invite-user.tsx” Error: [render-resolver] “onLoad” filter is not a valid Go regular expression: “C:UsersHPDesktopCalanderManagementSystemshedularemailtrialreact-email-starteremailsvercel-invite-user.tsx” at C:UsersHPDesktopCalanderManagementSystemshedularemailtrialreact-email-starternode_modulesesbuildlibmain.js:1084:25 at responseCallbacks. (C:UsersHPDesktopCalanderManagementSystemshedularemailtrialreact-email-starternode_modulesesbuildlibmain.js:704:9) at handleIncomingPacket (C:UsersHPDesktopCalanderManagementSystemshedularemailtrialreact-email-starternode_modulesesbuildlibmain.js:762:9) at Socket.readFromStdout (C:UsersHPDesktopCalanderManagementSystemshedularemailtrialreact-email-starternode_modulesesbuildlibmain.js:680:7) at Socket.emit […]

NextJS | How to stop bundling css in NextJS 13 or 14

I am running a server side rendereded Next 13 app. I am having issue related to Largest Contentful paint which is getting affected because the bundled css files are loading at the highest priority and causing render blocking issue. Is there any way to de prioritize the css or stop adding it from the server rendered html?