NextJS Tips Series: Static HTML export

next exportexports your app to static HTML, which can be run standalone without the need of a Node.js server (for those who want to buy a template on HTML format on any marketplace like Envato ThemeForest, etc..).

The exported app supports almost every feature of Next.js, incl. dynamic routes, prefetching, preloading and dynamic imports.

// Package.json
"scripts": {
"build": "next build && next export"
}

Thank you :)

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Said BADAOUI

Said BADAOUI

201 Followers

JavaScript || Reactjs || Nextjs || Nodejs || Python || Front-end Developer