Skip to content

Commit

Permalink
fix(typescript): explicitly enable allowSyntheticDefaultImports
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 committed Aug 3, 2018
1 parent 3894a4a commit 350f77b
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"experimentalDecorators": true,
<%_ } _%>
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
"sourceMap": true,
"baseUrl": ".",
"types": [
Expand Down

2 comments on commit 350f77b

@DanielRosenwasser
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since you're using module: esnext, you shouldn't even need esModuleInterop, right @weswigham? allowSyntheticDefaultImports should provide the appropriate error messages for an import * as foo when it definitely won't work.

@weswigham
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They don't quite infer one another. You need the interop flag for the new error - we hid it behind it

Please sign in to comment.