Skip to content

官方例子运行不起来 #131

Open
@chenshuanj

Description

@chenshuanj

https://gpt-vis.antv.vision/components/line 的 demo 下载运行提示:

ERROR in ./src/App.js 36:30-34
export 'Line' (imported as 'Line') was not found in '@antv/gpt-vis' (module has no exports)
ERROR in ./node_modules/@antv/gpt-vis/dist/esm/index.js 2:0-25
Module not found: Error: Can't resolve './export' in 'D:\nodejs\antd-demo\node_modules@antv\gpt-vis\dist\esm'
Did you mean 'export.js'?
BREAKING CHANGE: The request './export' failed to resolve only because it was resolved as fully specified
(probably because the origin is strict EcmaScript Module, e. g. a module with javascript mimetype, a '.mjs' file, or a '.js' file where the package.json contains '"type": "module"').
The extension in the request is mandatory for it to be fully specified.
Add the extension to the request.
ERROR in ./node_modules/@antv/gpt-vis/dist/esm/index.js 5:0-24
Module not found: Error: Can't resolve './types' in 'D:\nodejs\antd-demo\node_modules@antv\gpt-vis\dist\esm'
Did you mean 'index.js'?
BREAKING CHANGE: The request './types' failed to resolve only because it was resolved as fully specified
(probably because the origin is strict EcmaScript Module, e. g. a module with javascript mimetype, a '.mjs' file, or a '.js' file where the package.json contains '"type": "module"').
The extension in the request is mandatory for it to be fully specified.
Add the extension to the request.
ERROR in ./node_modules/@antv/gpt-vis/dist/esm/index.js 8:0-72
Module not found: Error: Can't resolve './ChartCodeRender' in 'D:\nodejs\antd-demo\node_modules@antv\gpt-vis\dist\esm'
Did you mean 'index.js'?
BREAKING CHANGE: The request './ChartCodeRender' failed to resolve only because it was resolved as fully specified
(probably because the origin is strict EcmaScript Module, e. g. a module with javascript mimetype, a '.mjs' file, or a '.js' file where the package.json contains '"type": "module"').
The extension in the request is mandatory for it to be fully specified.
Add the extension to the request.
...

是哪里不对?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions