forked from youzan/vant
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[new feature] Docs: contribute.md 移动至 .github 下 (youzan#212)
* move contribute to .github * fix wrong name * move markdown.md to .github
- Loading branch information
1 parent
2f2eaaf
commit b7dd98c
Showing
6 changed files
with
32 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,43 +1,41 @@ | ||
# Vant Contributing Guide | ||
# Contributing to Vant | ||
|
||
## 开发环境 | ||
The following is a set of guidelines for contributing to Vant. Please spend several minutes in reading these guidelines before you create an issue or pull request. | ||
|
||
当你克隆好仓库后,运行: | ||
Anyway, these are just guidelines, not rules, use your best judgment and feel free to propose changes to this document in a pull request. | ||
|
||
```shell | ||
yarn || npm i | ||
``` | ||
## Opening an Issue | ||
If you think you have found a bug, or have a new feature idea, please start by making sure it hasn't already been reported or fixed. You can search through existing issues and PRs to see if someone has reported one similar to yours. | ||
|
||
Next, create a new issue that briefly explains the problem, and provides a bit of background as to the circumstances that triggered it, and steps to reproduce it. | ||
|
||
## Submitting a Pull Request | ||
It's welcomed to pull request, And there are some tips about that: | ||
|
||
- Before working on a large change, it is best to open an issue first to discuss it with the maintainers. | ||
|
||
- When in doubt, keep your pull requests small. To give a PR the best chance of getting accepted, don't bundle more than one feature or bug fix per pull request. It's always best to create two smaller PRs than one big one. | ||
|
||
- When adding new features or modifying existing, please attempt to include tests to confirm the new behaviour. | ||
|
||
### 常用的npm scripts | ||
- Rebase before creating a PR to keep commit history clear. | ||
|
||
```shell | ||
# watch和自动build,并启动一个静态服务器 | ||
$ npm run dev | ||
- Add some descriptions and refer relative issues for you PR. | ||
|
||
# 代码规范校验 | ||
$ npm run lint | ||
## Getting started | ||
|
||
# unit test watch | ||
$ npm run test:watch | ||
```bash | ||
git clone [email protected]:youzan/vant.git | ||
|
||
# test | ||
$ npm run test | ||
yarn | ||
|
||
# 打包 | ||
$ npm run dist | ||
npm run dev | ||
|
||
# gh-pages分支deploy | ||
$ npm run deploy | ||
# open http://localhost:8080 | ||
``` | ||
|
||
### 项目目录结构 | ||
|
||
- build:打包配置 | ||
- docs:文档目录 | ||
- examples-dist:手机端md文件,自动生成,请勿改动 | ||
- examples-docs:PC端文档md文件 | ||
- src:文档页项目代码 | ||
- lib:打包后生成的文件 | ||
- packages:组件目录,每个组件是一个目录 | ||
- src:主文件以及一些公用的`mixins`和`utils` | ||
- test:测试用例 | ||
## Component Developing Guidelines | ||
- Create new directory under `packages` for a new component. | ||
- All the style code are located under `packages/vant-css/src`. | ||
- Refer to `Sku` for nested components. | ||
- Refer to `Button` for components that depend on other components. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.