The issue has been closed
问题描述
These line of code seems having an issue
import { Graph, Extensions, extend } from '@antv/g6';
const ExtGraph = extend(Graph, {
transforms: { 'transform-v4-data': Extensions.TransformV4Data },
nodes: {
'sphere-node': Extensions.SphereNode,
},
behaviors: {
'orbit-canvas-3d': Extensions.OrbitCanvas3D,
'zoom-canvas-3d': Extensions.ZoomCanvas3D,
'hover-activate': Extensions.HoverActivate,
'brush-select': Extensions.BrushSelect,
},
});
Extensions and extend seems not exported in antv/g6.
It can be reproduce with your example as https://g6-next.antv.antgroup.com/en/examples/feature/features/#lodLevels
重现链接
https://codesandbox.io/s/452wyj
重现步骤
npm run build
预期行为
Compilation OK
平台
ubuntu
G6 V5
package.json
屏幕截图或视频(可选)
No response
补充说明(可选)
No response

Ant-G6@0.1.0 build
craco build
Creating an optimized production build...
One of your dependencies, babel-preset-react-app, is importing the
"@babel/plugin-proposal-private-property-in-object" package without
declaring it in its dependencies. This is currently working because
"@babel/plugin-proposal-private-property-in-object" is already in your
node_modules folder for unrelated reasons, but it may break at any time.
babel-preset-react-app is part of the create-react-app project, which
is not maintianed anymore. It is thus unlikely that this bug will
ever be fixed. Add "@babel/plugin-proposal-private-property-in-object" to
your devDependencies to work around this error. This will make this message
go away.
Failed to compile.
Attempted import error: 'extend' is not exported from '@antv/g6' (imported as 'extend').
posted by romaderi12 12 months ago
posted by romaderi12 12 months ago 
请看最新文档,issue中的用法 api 是被移出的。
posted by hustcc 11 months ago