Skip to content

Commit

Permalink
📝 update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
zxc0328 committed Nov 22, 2019
1 parent 9a39c8a commit dd9daff
Show file tree
Hide file tree
Showing 7 changed files with 470 additions and 289 deletions.
54 changes: 54 additions & 0 deletions packages/graphin-components/README-cn.ZH.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
## @antv/graphin-components

[English](./README.md)

这是 Graphin 的辅助分析 React 组件库。Graphin 是基于 [G6 3.x](https://github.com/antvis/g6) 的图分析解决方案。

主要包括:

- Toolbar 工具栏
- ContextMenu 右键菜单
- 更多组件开发中...

## 安装

```bash

npm install @antv/graphin-components --save

```

## 使用

```tsx
import React from 'react';
import ReactDOM from 'react-dom';
import Graphin, { Utils } from '@antv/graphin';
import { Toolbar } from '@antv/graphin-components';

// 别忘了引入 CSS
import '@antv/graphin/dist/index.css';
import '@antv/graphin-components/dist/index.css';

const App = () => {
const data = Utils.mock(10).graphin();
return (
<div className="App">
<Graphin data={data}>
<Toolbar />
</Graphin>
</div>
);
};

const rootElement = document.getElementById('root');
ReactDOM.render(<App />, rootElement);
```

## 文档

请参考 [Graphin 文档-分析组件](https://graphin.antv.vision/zh/docs/manual/main-concepts/components)

## APIs

请参考[Graphin 分析组件 API 文档](https://graphin.antv.vision/zh/docs/api/components)
60 changes: 60 additions & 0 deletions packages/graphin-components/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
![](https://img.shields.io/badge/language-typescript-red.svg)
![](https://img.shields.io/badge/license-MIT-000000.svg)
[![npm package](https://img.shields.io/npm/v/@antv/graphin-components.svg)](https://www.npmjs.com/package/@antv/graphin)
[![NPM downloads](http://img.shields.io/npm/dm/@antv/graphin.svg)](https://npmjs.org/package/@antv/graphin)
[![Build Status](https://travis-ci.org/antvis/graphin.svg?branch=master)](https://travis-ci.org/antvis/graphin)

## @antv/graphin-components

[中文](./README-cn.ZH.md)

Graphin's components lib for building graph analysis studio. Graphin is the graph analysis toolkit based on [G6 3.x](https://github.com/antvis/g6).

Components list:

- Toolbar
- ContextMenu
- More coming soon...

## Install

```bash

npm install @antv/graphin-components --save

```

## Usage

```tsx
import React from 'react';
import ReactDOM from 'react-dom';
import Graphin, { Utils } from '@antv/graphin';
import { Toolbar } from '@antv/graphin-components';

// Do not forget to import CSS
import '@antv/graphin/dist/index.css';
import '@antv/graphin-components/dist/index.css';

const App = () => {
const data = Utils.mock(10).graphin();
return (
<div className="App">
<Graphin data={data}>
<Toolbar />
</Graphin>
</div>
);
};

const rootElement = document.getElementById('root');
ReactDOM.render(<App />, rootElement);
```

## Docs

Please refer to [Graphin Docs - Components](https://graphin.antv.vision/zh/docs/manual/main-concepts/components)

## APIs

Please refer to [Graphin Components API Doc](https://graphin.antv.vision/zh/docs/api/components)
Loading

0 comments on commit dd9daff

Please sign in to comment.