filmov
tv
How to generate build files in next js, with Error: Image Optimization using Next.js default loader
![preview_player](https://i.ytimg.com/vi/0PvJuejEFV0/maxresdefault.jpg)
Показать описание
distDir: 'build',
}
"scripts": {
"dev": "next", // development
"build": "next build && next export",// build next app to .next folder
"start": "next start", // start nextjs server for .next build folder
"prod": "next export" // export nextjs files as bundle like in react app
}
Then deploy the out directory to a static host. or run locally with npm run serve
}
"scripts": {
"dev": "next", // development
"build": "next build && next export",// build next app to .next folder
"start": "next start", // start nextjs server for .next build folder
"prod": "next export" // export nextjs files as bundle like in react app
}
Then deploy the out directory to a static host. or run locally with npm run serve