Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: add force layout demos #6685

Merged
merged 2 commits into from
Jan 3, 2025
Merged

docs: add force layout demos #6685

merged 2 commits into from
Jan 3, 2025

Conversation

yvonneyx
Copy link
Contributor

@yvonneyx yvonneyx commented Jan 2, 2025

  • 新增更多 force 布局示例

Copy link

Walkthrough

此PR新增了一些关于力导向布局的示例,主要是通过添加新的JavaScript文件和更新元数据文件来实现的。这些示例展示了如何使用@antv/g6库来创建具有不同节点和边的图形布局。

Changes

文件 概述
packages/site/examples/layout/force-directed/demo/functional-params.js 新增了一个JavaScript文件,定义了一个力导向布局的图形示例,包括节点和边的数据,以及布局和行为的配置。
packages/site/examples/layout/force-directed/demo/meta.json 更新了元数据文件,可能是为了支持新的示例展示。


const graph = new Graph({
container: 'container',
data,

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure that the container specified here is correctly set up in the HTML where this script is used. If the container is not found, the graph will not render, leading to potential confusion.

@yvonneyx yvonneyx merged commit e90ed66 into v5 Jan 3, 2025
2 checks passed
@yvonneyx yvonneyx deleted the docs/demos branch January 3, 2025 07:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants