Next.js Discord

Discord Forum

NPM RUN BUILD with no build

Unanswered
Brown bear posted this in #help-forum
Open in Discord
Brown bearOP
Hi, how can i do smth like "npm run build" to see if my app will build, without actually creating a build?

3 Replies

Jersey Wooly
Hey it's impossible 🙂
@Brown bear Hi, how can i do smth like "npm run build" to see if my app will build, without actually creating a build?
getting the output of npm run build without building is impossible as tamdoge said.

HOwever, you can still check your types and your application like that. Run npm run tsc or npm run lint to check your types. If you have testing script, then run them as well npm run test.

You dont want to do this manually. Install husky and put it into a github hook like pre-commit or similar. Then it happens automatically for and everything is fine ^^
@Brown bear solved?