-
-
Notifications
You must be signed in to change notification settings - Fork 233
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
Run TypeScript on the types #1042
Conversation
Not sure why this affects XO. |
I was about to open a PR doing exactly this! :) The change in xo behavior is probably due to the addition of Maybe this is related to #1040? Let's see if the problem persists after merging #1043. |
Yeah, would be nice if |
Looking into it now. 👀 |
The problem was that One of the type tests needed to be tweaked to avoid an implicit conversion to |
tsconfig.json
Outdated
"compilerOptions": { | ||
"module": "nodenext", | ||
"moduleResolution": "nodenext", | ||
"moduleDetection": "force", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The default value of moduleDetection
is auto
, which uses the package.json
type
field when module
is nodenext
. Since we use type: 'module'
in package.json
, it seems like we could remove the moduleDetection: "force"
line? tsc
seems to work without it.
tsd
only validates the types, it doesn't compile the code, so running TS too is helpful (and would have caught 3bdab60).