skip to Main Content

I created my first Next JS project with Tailwind and wanted to build it with "next build".
Then it created a folder ".next", but there is not a single .html file.

I come from the Angular world and there it simply works with "ng build".

I’m on All Inkl for my projects and of course it can’t read the Next JS files.

All files in my project are .js files

How can I make it run on my server like with Angular projects?

/** @type {import('next').NextConfig} */
const nextConfig = {
  output: 'export',
  images: {
    unoptimized: true,}
}

module.exports = nextConfig

I’ve tried everything Google and ChatGPT have suggested, but it just doesn’t work.

3

Answers


  1. Chosen as BEST ANSWER

    Thats my out folder and my package.json folders


  2. You need to run next start.

    If you bootstrapped your project with create-next-app then you should have a start script in your package.json, so should able to run either of these (depending on your package manager):

    • npm start
    • pnpm start
    • yarn start
    Login or Signup to reply.
  3. enter image description here

    You need to look for out dir. You will find the exported static file there.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search