You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Execute commands in the project directory npm install tsc --noEmit
Current Behavior
tsc --noEmit output:
main.mts:1:10 - error TS2305: Module '"echarts/core"' has no exported member 'init'.
1 import { init } from "echarts/core";
~~~~
node_modules/echarts/core.d.ts:20:15 - error TS2834: Relative import paths need explicit file extensions in ECMAScript imports when '--moduleResolution' is 'node16' or 'nodenext'. Consider adding an extension to the import path.
20 export * from './types/dist/core';
~~~~~~~~~~~~~~~~~~~
Found 2 errors in 2 files.
Errors Files
1 main.mts:1
1 node_modules/echarts/core.d.ts:20
vscode:
Expected Behavior
Setting module and moduleResolution to CommonJs and node respectively can work properly
echarts-botbot
changed the title
[Bug] Typescript setting module to "NodeNext" cannot obtain type prompt
[Bug] Typescript setting module to "NodeNext" cannot obtain type prompt
May 31, 2024
Version
5.5.0
Link to Minimal Reproduction
https://github.com/eavidy/test_case/tree/echart-1
Steps to Reproduce
git clone -b echart-1 git@github.com:eavidy/test_case.git
This example mainly includes two files
tsconfig.json:
main.mts :
npm install
tsc --noEmit
Current Behavior
tsc --noEmit
output:vscode:
Expected Behavior
Setting module and moduleResolution to CommonJs and node respectively can work properly
Can the NodeNext module for Typescript be supported?
Environment
Any additional comments?
No response
The text was updated successfully, but these errors were encountered: