Skip to content
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

Make TypeScript diagnostics non-fatal #9737

Closed
kitsonk opened this issue Mar 9, 2021 · 5 comments
Closed

Make TypeScript diagnostics non-fatal #9737

kitsonk opened this issue Mar 9, 2021 · 5 comments
Labels
cli related to cli/ dir suggestion suggestions for new features (yet to be agreed)

Comments

@kitsonk
Copy link
Contributor

kitsonk commented Mar 9, 2021

We might want to consider making TypeScript diagnostics effectively only "warnings" and go ahead and still attempt to run the program, instead of treating all TypeScript diagnostics as fatal.

It can get frustrating when trying to develop code, and get type checking, to have Deno exit all the time, when you know there is a type error (or the type error is outside of your control).

@kitsonk kitsonk added cli related to cli/ dir suggestion suggestions for new features (yet to be agreed) labels Mar 9, 2021
@wperron
Copy link
Contributor

wperron commented Mar 10, 2021

I think I remember a similar discussion on the Discord server, iirc the suggestion was to make --no-check the default behavior. I'd be happy with that, we'd just have to figure out a proper flag for the "strict type checking" behavior

@KotlinIsland
Copy link

DetachHead/ts-helpers#97

We can't use our project with deno because tsc strips @ts-ignore comments from the d.ts file.

"skipLibCheck": true is how you would work around with this in npm land, but I don't think it would work in deno.

@DetachHead
Copy link

skipLibCheck only applies to *.d.ts files. i definitely think it's a bad idea to mark all type errors as warnings including ones from your project (ie. *.ts files), but doing so only with *.d.ts files sounds good and would match how it works in node.

@lino-levan
Copy link
Contributor

@kitsonk I believe --no-check is essentially the default now. Should this issue be closed?

@bartlomieju
Copy link
Member

Yes, that's for pointing this out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cli related to cli/ dir suggestion suggestions for new features (yet to be agreed)
Projects
None yet
Development

No branches or pull requests

6 participants