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

Find a way to suppress the errors generated by importing modules #6114

Closed
raregrass opened this issue Dec 16, 2015 · 4 comments
Closed

Find a way to suppress the errors generated by importing modules #6114

raregrass opened this issue Dec 16, 2015 · 4 comments
Labels
Duplicate An existing issue was already created

Comments

@raregrass
Copy link

I need to use some external modules without .d.ts files, but, I do not want to use the corresponding third party .d.ts files. Please tell me how to just suppress the errors - "Cannot find the module ...", thinks.

@DanielRosenwasser
Copy link
Member

Would the ideas in #2709 be a suitable way of dealing with this? Something like:

import * as blah: any from "foo/bar";

@raregrass
Copy link
Author

Yes, I will go there for seeking the answer, thinks for your help!
BTW, I think the idea below is good and doesn't need to change any grammar in current project. It's more friendly for developers because sometimes someone maybe want to suppress a special kind of error for debugging and there isn't, maybe I have not noticed, any way to achieve this. Please consider this proposal.

if it was possible to explicitly ignore specific TS**** errors, that would be an acceptable workaround, e.g. something like this in tsconfig.json:

{
      ignoreRules: {
          "TS2307": true
      }
}

@DanielRosenwasser DanielRosenwasser added the Duplicate An existing issue was already created label Dec 17, 2015
@DanielRosenwasser
Copy link
Member

Sure, that's another issue as well (#4094). I'm going to close this as a duplicate of those issues.

@amcdnl
Copy link

amcdnl commented Jun 2, 2016

Would love to see this too.

@microsoft microsoft locked and limited conversation to collaborators Jun 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Duplicate An existing issue was already created
Projects
None yet
Development

No branches or pull requests

3 participants