-
Notifications
You must be signed in to change notification settings - Fork 27.7k
This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
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
Ability to pass a custom tsconfig for next dev
#8060
Comments
Aren't these specific flags better suited for a linter like ESLint? |
@Timer yep, for both: linters and IDEs. Not for dev servers - it interrupts the development process. So need to differentiate them by choosing different configs. P.S. There's also an issue on vscode repo - looks like it's hard to support choosing a custom config from their side: microsoft/vscode#12463 |
next dev
next dev
next dev
next dev
I agree right now overly strict TypeScript configurations can cause a bit of headache during development. Typically, this is solved by a separate As for now, we're going to start working to make TypeScript errors as unobtrusive as possible before we hand out the knobs to completely disable this integration. Please bear with us! 🙏 |
Even trying to disable this compiler error by setting "noUnusedLocals": false doesn't help, it looks like some tsconfig.json setting are ignored 🤔 |
i'd like to exclude |
When using an However I am not sure if it's right. More broadly I lack the knowledge on how to check precisely which files are included in which build to debug that. The interactions between VS Code, Next, and TypeScript are unclear to the end user. |
I followed this approach and it worked really well for me. Thanks! |
Is there any plans to support this in the near future? This is causing me a lot of headaches because Next is trying to compile my test setup files in my root which means I have to have my test dependencies in |
Funky bug I had today: |
Now that TypeScript 4.1 is out with I suppose as suggested in facebook/create-react-app#10025, it would be possible to default to My question, which I also posed in the CRA issue above, is whether there are large, useful differences in functionality between |
This issue was moved to a discussion.
You can continue the conversation there. Go to discussion →
Feature request
Is your feature request related to a problem? Please describe.
I'm bored of seeing
someVar is declared but its value is never read
:I'm actively write and delete code, exploring some libraries' features - I don't want my dev server to stuck me into an error. Of course it's bad to leave them. Of course my IDE should highlight that - and for that reason, I want to have
noUnusedLocals
ornoUnusedParameters
,strict
in overall. Of course there should be some pre-commit hook that will prevent me from committing this clutter into the repository. But I don’t want my dev server to thrownoUnusedLocals
andnoUnusedParameters
- I don't want it to prevent me playing with the code.UPD. That’s okay for the default behavior, but there should be an option that these keys should be enabled by VSCode, and by linter, but not used by dev server so it won’t throw error that prevents you to do anything.
Describe the solution you'd like
I'd like an ability of passing a tsconfig path for
next dev
command.Something like:
While I can use the original tsconfig.json for my IDE.
Describe alternatives you've considered
Well, I could make an issue for IDE (
vscode
doesn't support anything other thantsconfig.json
too), but anyway - both sides should support that.UPD. There's one: microsoft/vscode#12463. Still, both sides should support that.
Additional context
Idk maybe it's possible. But I don't see it from
next dev --help
:The text was updated successfully, but these errors were encountered: