antvis/G6

在ts中导入@antv/g6 v5时报错 #5772

whl1207 posted onGitHub

问题描述

代码为: import { Graph } from '@antv/g6'; 错误提示为: 模块 ""@antv/g6"" 没有导出的成员 "Graph"。你是想改用 "import Graph from "@antv/g6"" 吗?ts(2614)

重现链接

重现步骤

代码为: import { Graph } from '@antv/g6'; 错误提示为: 模块 ""@antv/g6"" 没有导出的成员 "Graph"。你是想改用 "import Graph from "@antv/g6"" 吗?ts(2614)

预期行为

ts不报错

平台

  • 操作系统: [Windows]
  • 网页浏览器: [Google Chrome, Safari, Firefox]
  • G6 版本: [5.0.0]
  • electron无法打包

屏幕截图或视频(可选)

No response

补充说明(可选)

No response


检查一下 node_modules 中的实际安装版本呢

posted by Aarebecca 11 months ago

Fund this Issue

$0.00
Funded

Pull requests