`import =` is not supported by @babel/plugin-transform-typescript
See original GitHub issueFor Int64 the generated code is:
import Int64 = require("node-int64");
But this syntax is not supported by @babel/plugin-transform-typescript, and I think
import Int64 from "node-int64"
should work the same.
I wonder why choosed to use import =
statement?
Issue Analytics
- State:
- Created 5 years ago
- Reactions:2
- Comments:6 (1 by maintainers)
Top Results From Across the Web
Typescript import = is not supported. #7062 - babel ... - GitHub
When importing a module using export =, TypeScript-specific import module = require("module") must be used to import the module. Current ...
Read more >babel/plugin-transform-typescript
This plugin adds support for the types syntax used by the TypeScript programming language. ... This is so that we know that the...
Read more >`import =` is not supported by @babel/plugin-transform ...
I end up with the following error though when compiling: import = is not supported by @babel/plugin-transform-typescript Please consider using ...
Read more >babel/plugin-transform-typescript
Workaround: Remove the const , which makes it available at runtime. Does not support export = and import = , because those cannot...
Read more >@babel/plugin-transform-typescript - npm
Transform TypeScript into ES.next. Latest version: 7.20.7, last published: 2 days ago. Start using @babel/plugin-transform-typescript in ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’ve opened #155 to update the thrift-server output to imit
import =
statements. Doing this for the apache output might be a little harder, but I have not looked at it closely.I also have this problem.
I change
import Int64 = require("node-int64");
toimport Int64 from "node-int64";
, that make mynext.js
api work