Giter Club home page Giter Club logo

Comments (2)

DevanAbinaya avatar DevanAbinaya commented on May 31, 2024 1

hi, it's not a bug, I'll tell you what's wrong here,

First Problem

first of all npm run dev is not a build command, build command is npm run build.

Second Problem

the second mistake is never run dev on production, only start with start command either using npm run start or other start command.

Third Problem

third, if you following the documentation for local development here that's not intended for vercel deployment, as the name said it is for developing the app not deploying it, it has a different configuration for vercel deployment.

Fourth Problem you will get error if you don't change your build script in your package.json file

this app required you to have a postgresql database by adding it in your .env file, since I'm using prisma for doing CRUD function it's mandatory to run at least once before building the app, so if you can't access the build command by console you have to include the command in your build script inside package.json, like this:

"build": "npx prisma generate && npx prisma migrate deploy && next build"

If you don't know how deploying next.js app to vercel works, I suggest you to learn it first then deploy this app as you want. I only support the use of this code as a learning material. So please use it with responsible, thanks.

from moopa.

Naiml007 avatar Naiml007 commented on May 31, 2024

tnx <3

from moopa.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.