Skip to content

Commit

Permalink
docs: add changelog contribute note
Browse files Browse the repository at this point in the history
  • Loading branch information
xiguaxigua committed Jun 19, 2018
1 parent 19683fb commit fd80075
Show file tree
Hide file tree
Showing 10 changed files with 1,966 additions and 210 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<a name="1.17.3"></a>
## [1.17.3](https://github.com/ElemeFE/v-charts/compare/v1.17.2...v1.17.3) (2018-06-19)


### Features

* **funnel:** add `filterZero` and `useDefaultOrder` attribute in settings ([#373](https://github.com/ElemeFE/v-charts/issues/373)) ([687491d](https://github.com/ElemeFE/v-charts/commit/687491d))
7 changes: 7 additions & 0 deletions CHANGELOG_CN.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<a name="1.17.3"></a>
## [1.17.3](https://github.com/ElemeFE/v-charts/compare/v1.17.2...v1.17.3) (2018-06-19)


### Features

* **funnel:** 增加 `filterZero``useDefaultOrder` 配置 ([#373](https://github.com/ElemeFE/v-charts/issues/373)) ([687491d](https://github.com/ElemeFE/v-charts/commit/687491d))
35 changes: 35 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# v-charts Contributing Guide

v-charts is a Vue2.x package-based Echarts chart component that provides developers with services to quickly generate charts.
The growth of v-charts is inseparable from everyone's support. If you would like to contribute code for v-charts, please read the following:

## Development principles

The core principle of v-charts is that developers can **simplify configuration items**. Based on this principle, v-charts has the following conventions:

1. The data needs to use the form of metrics dimension. For details,
please refer to [document](https://v-charts.js.org/#/en/data).
2. The setting of metrics dimensions, data types, simplified configuration items,
data aliases, etc. are achieved through the addition of attributes in settings.
3. In addition to introducing the dependency (eg: line) of the corresponding
module, the component tries not to introduce plug-in dependencies (eg: visualMap).

## Setting up the env

- Installation dependencies `npm install`
- Run development `npm run dev`
- Generate components `npm run build`
- Run the document `npm run docs`
- Run the test `npm run test`

## Component development

To develop a new chart component, first add the corresponding chart under
`src/packages`, then add the corresponding data under `examples/data` and
import it in `index.js`, and finally add corresponding components in
`src/index.es.js`, `src/component-list` and `src/index/index.js`. After development,
you need to add docs in `docs` folder and add it to sidebar.

## Code Style

Follow [standard](https://standardjs.com/).
31 changes: 31 additions & 0 deletions CONTRIBUTING_CN.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# v-charts 贡献指南

v-charts 是一套基于 Vue2.x 封装的 Echarts 图表组件,用于为开发者提供快速生成图表的服务。
v-charts 的成长离不开大家的支持,如果你愿意为 v-charts 贡献代码,请阅读以下内容:

## 开发原则

v-charts 的核心原则是**为开发者简化配置项**,基于此原则,v-charts 有如下约定:

1. 数据需要*尽量*使用指标维度的形式,具体可以参考[文档](https://v-charts.js.org/#/data)
2. 指标维度的设置、数据类型、简化的配置项、数据别名 等通过在 settings 中增加的属性实现。
3. 组件除引入相应模块的依赖(eg: line)外,*尽量*不引入插件的依赖(eg: visualMap)。

## 环境搭建

- 安装依赖 `npm install`
- 运行开发 `npm run dev`
- 生成组件 `npm run build`
- 运行文档 `npm run docs`
- 运行测试 `npm run test`

## 组件开发

开发新的图表组件,需要首先在 `src/packages` 下增加对应图表,然后在 `examples/data`
下增加对应数据并在 `index.js` 中引入,最后在 `src/component-list``src/index.es.js`
`src/index/index.js` 中增加对应的组件即可。开发完成后,需要在 `docs` 文件夹下,
增加相应文档,并将文档加到侧边栏中。

## 代码规范

遵循 [standard](https://standardjs.com/) 即可。
102 changes: 73 additions & 29 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,30 +1,66 @@
# v-charts
<p align="center">
<img src="./examples/favicon.ico" alt="mark text" width="100" height="100">
</p>

[![Build Status](https://travis-ci.org/ElemeFE/v-charts.svg?branch=master)](https://travis-ci.org/ElemeFE/v-charts)
[![NPM downloads](http://img.shields.io/npm/dm/v-charts.svg)](https://npmjs.org/package/v-charts)
![JS gzip size](http://img.badgesize.io/https://unpkg.com/v-charts/lib/index.js?compression=gzip&label=gzip%20size:%20JS)
[![Npm package](https://img.shields.io/npm/v/v-charts.svg)](https://www.npmjs.org/package/v-charts)
![Language](https://img.shields.io/badge/language-javascript-yellow.svg)
![License](https://img.shields.io/badge/license-MIT-000000.svg)
[![Join the chat at https://gitter.im/ElemeFE/v-charts](https://badges.gitter.im/ElemeFE/v-charts.svg)](https://gitter.im/ElemeFE/v-charts?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
<h3 align="center">v-charts</h3>

在使用echarts生成图表时,经常需要做繁琐的数据类型转化、修改复杂的配置项,v-charts的出现正是为了解决这个
痛点。基于Vue2.0和echarts封装的v-charts图表组件,只需要统一提供一种对前后端都友好的数据格式
设置简单的配置项,便可轻松生成常见的图表。
<p align="center">
<a href="https://travis-ci.org/ElemeFE/v-charts">
<img src="https://travis-ci.org/ElemeFE/v-charts.svg?branch=master" alt="Build Status">
</a>
<a href="https://npmjs.org/package/v-charts">
<img src="http://img.shields.io/npm/dm/v-charts.svg" alt="NPM downloads">
</a>
<a href="https://www.npmjs.org/package/v-charts">
<img src="https://img.shields.io/npm/v/v-charts.svg" alt="Npm package">
</a>
<a>
<img src="https://img.shields.io/badge/language-javascript-yellow.svg" alt="Language">
</a>
<a>
<img src="https://img.shields.io/badge/license-MIT-000000.svg" alt="License">
</a>
<a href="https://gitter.im/ElemeFE/v-charts?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge">
<img src="https://badges.gitter.im/ElemeFE/v-charts.svg" alt="Join the chat">
</a>
</p>

### 安装
---
<p align="center">
<a href="https://v-charts.js.org/#/en/">
Document
</a>
<span> | </span>
<a href="https://codesandbox.io/s/z69myovqzx">
Sample Project
</a>
<span> | </span>
<a>
English
</a>
<span> | </span>
<a href="./README_CN.md">
中文
</a>
</p>

> Chart components based on Vue2.x and Echarts
## Features
- **Uniform data format:** Use an uniform data format that both convient for frontend and backend, and also easy to create and edit.
- **Simplified configuration:** With simplified configuration items, complex requirements can be easily implemented.
- **Simple customization:** Provide a variety of custom Echarts way, you can easily set the chart options.

## Support

Modern browsers and Internet Explorer 10+, include pc and mobile browser.

## Install

```
npm i v-charts echarts -S
```

### 文档
---

[v-charts.js.org](https://v-charts.js.org)

### 快速上手
## Start
---

```html
Expand All @@ -35,18 +71,18 @@ npm i v-charts echarts -S
</template>

<script>
import VeLine from 'v-charts/lib/line'
import VeLine from 'v-charts/lib/line.common'
export default {
created () {
this.chartData = {
columns: ['日期', '销售量'],
columns: ['date', 'PV'],
rows: [
{ '日期': '1月1日', '销售量': 123 },
{ '日期': '1月2日', '销售量': 1223 },
{ '日期': '1月3日', '销售量': 2123 },
{ '日期': '1月4日', '销售量': 4123 },
{ '日期': '1月5日', '销售量': 3123 },
{ '日期': '1月6日', '销售量': 7123 }
{ 'date': '01-01', 'PV': 1231 },
{ 'date': '01-02', 'PV': 1223 },
{ 'date': '01-03', 'PV': 2123 },
{ 'date': '01-04', 'PV': 4123 },
{ 'date': '01-05', 'PV': 3123 },
{ 'date': '01-06', 'PV': 7123 }
]
}
},
Expand All @@ -56,7 +92,15 @@ export default {
</script>
```

### LICENSE
---
## Changelog

[中文](./CHANGELOG_CN.md) | [English](./CHANGELOG.md)

## Contribution

[中文](./CONTRIBUTING_CN.md) | [English](./CONTRIBUTING.md)


## License

MIT
107 changes: 107 additions & 0 deletions README_CN.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
<p align="center">
<img src="./examples/favicon.ico" alt="mark text" width="100" height="100">
</p>

<h3 align="center">v-charts</h3>

<p align="center">
<a href="https://travis-ci.org/ElemeFE/v-charts">
<img src="https://travis-ci.org/ElemeFE/v-charts.svg?branch=master" alt="Build Status">
</a>
<a href="https://npmjs.org/package/v-charts">
<img src="http://img.shields.io/npm/dm/v-charts.svg" alt="NPM downloads">
</a>
<a href="https://www.npmjs.org/package/v-charts">
<img src="https://img.shields.io/npm/v/v-charts.svg" alt="Npm package">
</a>
<a>
<img src="https://img.shields.io/badge/language-javascript-yellow.svg" alt="Language">
</a>
<a>
<img src="https://img.shields.io/badge/license-MIT-000000.svg" alt="License">
</a>
<a href="https://gitter.im/ElemeFE/v-charts?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge">
<img src="https://badges.gitter.im/ElemeFE/v-charts.svg" alt="Join the chat">
</a>
</p>

<p align="center">
<a href="https://v-charts.js.org">
文档
</a>
<span> | </span>
<a href="https://codesandbox.io/s/z69myovqzx">
示例项目
</a>
<span> | </span>
<a href="./README.md">
English
</a>
<span> | </span>
<a>
中文
</a>
</p>

> 基于 Vue2.x 封装的 Echarts 图表组件
## 特性

- **统一的数据格式:** 使用对前后端都友好的数据格式,方便生成和修改。
- **简化的配置项:** 通过简化的配置项,可以轻松实现复杂需求。
- **定制简单:** 提供多种自定义 Echarts 方式,可以方便的设置图表配置项。

## 支持性

支持所有现代浏览器及 IE10+ ,包括 pc 端和移动端。

## 安装

```
npm i v-charts echarts -S
```

## 快速上手
---

```html
<template>
<div>
<ve-line :data="chartData"></ve-line>
</div>
</template>

<script>
import VeLine from 'v-charts/lib/line.common'
export default {
created () {
this.chartData = {
columns: ['日期', '销售量'],
rows: [
{ '日期': '1月1日', '销售量': 123 },
{ '日期': '1月2日', '销售量': 1223 },
{ '日期': '1月3日', '销售量': 2123 },
{ '日期': '1月4日', '销售量': 4123 },
{ '日期': '1月5日', '销售量': 3123 },
{ '日期': '1月6日', '销售量': 7123 }
]
}
},
components: { VeLine }
}
</script>
```

## 更新日志

[中文](./CHANGELOG_CN.md) | [English](./CHANGELOG.md)

## 贡献

[中文](./CONTRIBUTING_CN.md) | [English](./CONTRIBUTING.md)


## License

MIT
4 changes: 2 additions & 2 deletions docs/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
]
window.$docsify = {
name: 'v-charts',
repo: 'https://github.com/elemefe/v-charts',
repo: 'https://github.com/ElemeFE/v-charts',
loadSidebar: 'sidebar.md',
ga: 'UA-120605025-3',
homepage: 'install.md',
Expand All @@ -60,7 +60,7 @@
loadNavbar: 'navbar.md',
plugins: [
EditOnGithubPlugin.create(
'https://github.com/elemefe/v-charts/blob/master/docs/'
'https://github.com/ElemeFE/v-charts/blob/master/docs/'
),
function (hook, vm) {
function i18n() {
Expand Down
Loading

0 comments on commit fd80075

Please sign in to comment.