{"repo":"devlpr-nitish/nextjs-frappe","free":true,"listed":false,"github":"https://github.com/devlpr-nitish/nextjs-frappe","clone":"git clone https://github.com/devlpr-nitish/nextjs-frappe.git","description":"A shell script that drops a full Next.js SSR frontend into any Frappe custom app — proxy routing, shared session, CSRF handled server-side, and automatic setup on install. One command.","language":"HTML","stars":11,"topics":["frappe","nextjs"],"license":"MIT","category":"cli-tools","readme_excerpt":"Why My First Next.js + Frappe Integration Failed — And How I Fixed It by Nitish Kumar · devlprnitish.tech --- A few months ago I published a shell script that scaffolded a Next.js frontend inside a Frappe custom app. The README looked clean. The setup worked locally. I wrote a blog post about it. It failed in production. Not dramatically — it just quietly didn't do what I thought it did. This post explains exactly what was wrong with that first approach, why it was fundamentally broken for anything beyond a landing page, and what the new version does differently. If you used the original script, read this before building anything serious on top of it. --- What the original script actually built The first version was built around one key line in next.config.ts : output: \"export\" tells Next.js to pre-render every page into flat HTML files at build time. The shell script would then: 1. Run npm run build to generate an out/ directory of static HTML/CSS/JS 2. Copy those files into Frappe's public/ folder 3. Run a postbuild.mjs script that walked every HTML file and injected Jinja template variables ( {{ frappe.session.csrf token }} , {{ boot tojson }} ) before 4. Generate www/ Python files for each route so Frappe served them as pages The idea was that Frappe's template engine would fill in the CSRF token and boot data at serve time, giving you something that felt dynamic. It didn't work the way I thought. --- Why it failed Problem 1: Static export is not Server-Side Rendering The","default_branch":null,"files":null,"tree":[],"storefront":"/r/devlpr-nitish","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/devlpr-nitish/nextjs-frappe/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}