github.com/insionng/yougam@v0.0.0-20170714101924-2bc18d833463/public/libs/vue-1.0.24/CONTRIBUTING.md (about) 1 # Vue.js Contributing Guide 2 3 Hi! I’m really excited that you are interested in contributing to Vue.js. Before submitting your contribution though, please make sure to take a moment and read through the following guidelines. 4 5 ## Issue Reporting Guidelines 6 7 - The issue list of this repo is **exclusively** for bug reports and feature requests. For simple questions, please use either [Gitter](https://gitter.im/vuejs/vue) or [the official forum](http://forum.vuejs.org/). 8 9 - Try to search for your issue, it may have already been answered or even fixed in the development branch. 10 11 - Check if the issue is reproducible with the latest stable version of Vue. If you are using a pre-release, please indicate the specific version you are using. 12 13 - It is **required** that you clearly describe the steps necessary to reproduce the issue you are running into. Issues with no clear repro steps will not be triaged. If an issue labeled "need repro" receives no further input from the issue author for more than 5 days, it will be closed. 14 15 - It is recommended that you make a JSFiddle/JSBin/Codepen to demonstrate your issue. You could start with [this template](http://jsfiddle.net/5sH6A/) that already includes the latest version of Vue. 16 17 - For bugs that involves build setups, you can create a reproduction repository with steps in the README. 18 19 - If your issue is resolved but still open, don’t hesitate to close it. In case you found a solution by yourself, it could be helpful to explain how you fixed it. 20 21 ## Pull Request Guidelines 22 23 - Checkout a topic branch from `dev` and merge back against `dev`. 24 25 - Work in the `src` folder and **DO NOT** checkin `dist` in the commits. 26 27 - Squash the commit if there are too many small ones. 28 29 - Follow the [code style](#code-style). 30 31 - Make sure `npm test` passes. (see [development setup](#development-setup)) 32 33 - If adding new feature: 34 - Add accompanying test case. 35 - Provide convincing reason to add this feature. Ideally you should open a suggestion issue first and have it greenlighted before working on it. 36 37 - If fixing a bug: 38 - Provide detailed description of the bug in the PR. Live demo preferred. 39 - Add appropriate test coverage if applicable. 40 41 ## Code Style 42 43 - [No semicolons unless necessary](http://inimino.org/~inimino/blog/javascript_semicolons). 44 45 - Follow JSDoc. 46 47 - 2 spaces indentation. 48 49 - multiple var declarations. 50 51 - 1 space after `function` and function names. 52 53 - 1 space between arguments, but not between parentheses. 54 55 - Break long ternary conditionals like this: 56 57 ``` js 58 var a = superLongConditionalStatement 59 ? 'yep' 60 : 'nope' 61 ``` 62 63 - When in doubt, read the source code. 64 65 ## Development Setup 66 67 You will need [Node.js](http://nodejs.org). 68 69 ``` bash 70 $ npm install 71 # optional: install pre-commit lint hook 72 $ npm run install-hook 73 ``` 74 75 Dev mode: watch and auto-build `dist/vue.js` and serve unit tests at `http://localhost:8080` during development: 76 77 ``` bash 78 $ npm run dev 79 ``` 80 81 To lint: 82 83 ``` bash 84 $ npm run lint 85 ``` 86 87 To build: 88 89 ``` bash 90 $ npm run build 91 ``` 92 93 Run default test suite: 94 95 ``` bash 96 $ npm test 97 ``` 98 99 The default test script will do the following: lint -> unit tests with coverage -> build -> e2e tests. **Please make sure to have this pass successfully before submitting a PR.** 100 101 The unit tests are written with [Jasmine](http://jasmine.github.io/2.3/introduction.html) and run with [Karma](http://karma-runner.github.io/0.13/index.html). The e2e tests are written for and run with [CasperJS](http://casperjs.org/).