-
Notifications
You must be signed in to change notification settings - Fork 27k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Slow development with TypeScript #8841
Comments
Can you please share your entire project? That'll be the only way we can get this fixed. You can share it in private. |
@Timer really sorry, it's a commercial project and I can't share. I'm wondering why "bundled successfully, waiting for typecheck results" message appears despite my efforts. Is there anything else can be done for NextJS to skip type-checking? I'm not sure if this is a bug or not, since here @kachkaev seems to understand why it appears, but I don't. If it's not a bug, maybe I should post this to stackoverflow? |
That message is unrelated if you've modified your The message still appearing is just a side effect of you tweaking the Next.js configuration to remove a plugin it expects. I'll close this issue since it cannot be reproduced without your project. |
I'm also experiencing the slow development. FYI, I also use packages like typescript, styled-components, react-i18next... |
This comment has been minimized.
This comment has been minimized.
@kachkaev thanks it decreases the time a little. but it still takes more than 7 seconds |
I found |
@landvibe but nextjs seems to re-add this property the next time you start the project... |
@macrozone I think nextjs only adds it on initial start, and it does not re-add |
If you delete the property Next.js will re-add it. You need to explicitly set it to |
tsconfig |
@AliasT try this new option as well: https://nextjs.org/docs/api-reference/next.config.js/ignoring-typescript-errors |
I've been struggling with this issue for months, this seemed to solve my issue though. Now the compile time seems about the same as it would be with CRA. |
ignoreBuildErrors is amazing.... seriously, my wait time when I run next dev went down from ~30s to 10s, and tests are running in 5s instead of 40s.... that should be activated by default for test and dev. Thanks a lot! |
Type checking is disabled in development in the latest Next.js version btw (as we tracked down some massive slowdowns in the solution used to do type checking), compilation takes the same time for typescript and javascript since that change. |
|
have to switch back to the stable version :( the canary version has problems with
|
@coolgk this should be resolved in the latest canary of Next.js |
Can you point out how to enable back type checking? I've tried adding back the |
This issue has been automatically locked due to no recent activity. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you. |
Bug report
Describe the bug
My problems:
Context:
Also:
What I did so far:
node-modules
intsconfig.json
fork-ts-checker-webpack-plugin
typescript: { transpileOnly: true }
BUG (if it is):
There can be many factors effecting the speed. Would you suggest anything else?
To Reproduce
I can't really suggest how to reproduce, since it's a very complex project.
Expected behavior
I'd expect a fast development speed.
Screenshots
I can provide if needed...
System information
Additional context
next.config.js:
package.json:
nodemon.json
The text was updated successfully, but these errors were encountered: