antvis / antvis/Graphin

v1.5.0 升级到 v2.3.0 ,方法找不到了, 类似Layout.Dagre

Open
#313 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
1.1k
Forks
275
PR merge metrics
No merged PRs in 30d

Description

**Describe the bug**
升级之后,一些方法都找不到了
看了一下包
- graphin `v1.5.0` 对应版本 antv/g6 `v3.8.1`
- graphin `v2.3.0` 对应版本 antv/g6 `v4.3.4`
```ts
import { Layout } from '@antv/graphin';
// ......
// Dagre布局,返回布局后各个节点坐标
const layoutedNodes = Layout.Dagre({ nodes: lodash.values(dagreNodesMap), edges: dagreEdges }, { rankdir: 'LR', nodesep: V_GAP, ranksep: H_GAP });

```
**Expected behavior**
请问目前是否有解决方案,还是说必须重构代码了

Contributor guide

Open the contributing guide

Research direction

Start by inspecting the exported Layout API in @antv/graphin v2.3.0 and comparing it with v1.5.0, focusing on the Layout.Dagre call shown in the issue. Check the corresponding G6 versions and migration information to determine whether a supported replacement exists; done means identifying the v2-compatible API or documenting the required refactor.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
computer-graphics, frontend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.