You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: .github/CONTRIBUTING.md
+18-18
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# Vue.js Contributing Guide
2
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.
3
+
Hi! I'm really excited that you are interested in contributing to Vue.js. Before submitting your contribution, please make sure to take a moment and read through the following guidelines:
4
4
5
5
-[Code of Conduct](https://github.com/vuejs/vue/blob/dev/.github/CODE_OF_CONDUCT.md)
@@ -14,28 +14,28 @@ Hi! I’m really excited that you are interested in contributing to Vue.js. Befo
14
14
15
15
## Pull Request Guidelines
16
16
17
-
- The `master` branch is basically just a snapshot of the latest stable release. All development should be done in dedicated branches. **Do not submit PRs against the `master` branch.**
17
+
- The `master` branch is just a snapshot of the latest stable release. All development should be done in dedicated branches. **Do not submit PRs against the `master` branch.**
18
18
19
19
- Checkout a topic branch from the relevant branch, e.g. `dev`, and merge back against that branch.
20
20
21
21
- Work in the `src` folder and **DO NOT** checkin `dist` in the commits.
22
22
23
-
- It's OK to have multiple small commits as you work on the PR - we will let GitHub automatically squash it before merging.
23
+
- It's OK to have multiple small commits as you work on the PR - GitHub will automatically squash it before merging.
24
24
25
25
- Make sure `npm test` passes. (see [development setup](#development-setup))
26
26
27
27
- If adding new feature:
28
28
- Add accompanying test case.
29
-
- Provide convincing reason to add this feature. Ideally you should open a suggestion issue first and have it greenlighted before working on it.
29
+
- Provide convincing reason to add this feature. Ideally, you should open a suggestion issue first and have it approved before working on it.
30
30
31
-
- If fixing a bug:
32
-
- If you are resolving a special issue, add `(fix #xxxx[,#xxx])` (#xxxx is the issue id) in your PR title for a better release log, e.g. `update entities encoding/decoding (fix #3899)`.
31
+
- If fixing bug:
32
+
- If you are resolving a special issue, add `(fix #xxxx[,#xxxx])` (#xxxx is the issue id) in your PR title for a better release log, e.g. `update entities encoding/decoding (fix #3899)`.
33
33
- Provide detailed description of the bug in the PR. Live demo preferred.
34
34
- Add appropriate test coverage if applicable.
35
35
36
36
## Development Setup
37
37
38
-
You will need [Node.js](http://nodejs.org)**version 6+** and [Java Runtime Environment](http://www.oracle.com/technetwork/java/javase/downloads/index.html) (needed for running Selenium server during e2e tests).
38
+
You will need [Node.js](http://nodejs.org)**version 6+** and [Java Runtime Environment](http://www.oracle.com/technetwork/java/javase/downloads/index.html) (for running Selenium server during e2e tests).
39
39
40
40
After cloning the repo, run:
41
41
@@ -65,11 +65,11 @@ $ npm test
65
65
66
66
There are some other scripts available in the `scripts` section of the `package.json` file.
67
67
68
-
The default test script will do the following: lint with ESLint -> type check with Flow -> unit tests with coverage -> e2e tests. **Please make sure to have this pass successfully before submitting a PR.** Although the same tests will be run against your PR on the CI server, it is better to have it working locally beforehand.
68
+
The default test script will do the following: lint with ESLint -> type check with Flow -> unit tests with coverage -> e2e tests. **Please make sure to have this pass successfully before submitting a PR.** Although the same tests will be run against your PR on the CI server, it is better to have it working locally.
69
69
70
70
## Project Structure
71
71
72
-
-**`scripts`**: contains build-related scripts and configuration files. In most cases you don't need to touch them. However, it would be helpful to familiarize yourself with the following files:
72
+
-**`scripts`**: contains build-related scripts and configuration files. Usually, you don't need to touch them. However, it would be helpful to familiarize yourself with the following files:
73
73
74
74
-`scripts/alias.js`: module import aliases used across all source code and tests.
75
75
@@ -85,51 +85,51 @@ The default test script will do the following: lint with ESLint -> type check wi
85
85
86
86
-**`test`**: contains all tests. 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 [Nightwatch.js](http://nightwatchjs.org/).
87
87
88
-
-**`src`**: contains the source code, obviously. The codebase is written in ES2015 with [Flow](https://flowtype.org/) type annotations.
88
+
-**`src`**: contains the source code. The codebase is written in ES2015 with [Flow](https://flowtype.org/) type annotations.
89
89
90
90
-**`compiler`**: contains code for the template-to-render-function compiler.
91
91
92
-
The compiler consists of a parser (converts template strings to element ASTs), an optimizer (detects static trees for vdom render optimization), and a code generator (generate render function code from element ASTs). Note the codegen directly generates code strings from the element AST - it's done this way for smaller code size because the compiler is shipped to the browser in the standalone build.
92
+
The compiler consists of a parser (converts template strings to element ASTs), an optimizer (detects static trees for vdom render optimization), and a code generator (generate render function code from element ASTs). Note that codegen directly generates code strings from the element AST - it's done this way for smaller code size because the compiler is shipped to the browser in the standalone build.
The Vue 2.0 core is platform-agnostic - which means code inside `core`should be able to run in any JavaScript environment, be it the browser, Node.js, or an embedded JavaScript runtime in native applications.
96
+
The Vue 2.0 core is platform-agnostic. That is, code inside `core`is able to be run in any JavaScript environment, be it the browser, Node.js, or an embedded JavaScript runtime in native applications.
97
97
98
98
-**`observer`**: contains code related to the reactivity system.
99
99
100
100
-**`vdom`**: contains code related to vdom element creation and patching.
101
101
102
102
-**`instance`**: contains Vue instance constructor and prototype methods.
103
103
104
-
-**`global-api`**: as the name suggests.
104
+
-**`global-api`**: contains Vue global api.
105
105
106
-
-**`components`**: universal abstract components. Currently `keep-alive` is the only one.
Entry files for dist builds are located in their respective platform directory.
113
113
114
-
Each platform module contains three parts: `compiler`, `runtime` and `server`, corresponding to the three directories above. Each part contains platform-specific modules/utilities which are then imported and injected to the core counterparts in platform-specific entry files. For example, the code implementing the logic behind `v-bind:class` is in `platforms/web/runtime/modules/class.js` - which is imported in `entries/web-runtime.js` and used to create the browser-specific vdom patching function.
114
+
Each platform module contains three parts: `compiler`, `runtime` and `server`, corresponding to the three directories above. Each part contains platform-specific modules/utilities which are imported and injected to the core counterparts in platform-specific entry files. For example, the code implementing the logic behind `v-bind:class` is in `platforms/web/runtime/modules/class.js` - which is imported in `entries/web-runtime.js` and used to create the browser-specific vdom patching function.
115
115
116
116
-**`sfc`**: contains single-file component (`*.vue` files) parsing logic. This is used in the `vue-template-compiler` package.
117
117
118
118
-**`shared`**: contains utilities shared across the entire codebase.
119
119
120
120
-**`types`**: contains TypeScript type definitions
121
121
122
-
-**`test`**: type definitions tests
122
+
-**`test`**: contains type definitions tests
123
123
124
124
125
125
## Financial Contribution
126
126
127
-
As a pure community-driven project without major corporate backing, we also welcome financial contributions via Patreon or OpenCollective.
127
+
As a pure community-driven project without major corporate backing, we also welcome financial contributions via Patreon and OpenCollective.
128
128
129
129
-[Become a backer or sponsor on Patreon](https://www.patreon.com/evanyou)
130
130
-[Become a backer or sponsor on OpenCollective](https://opencollective.com/vuejs)
131
131
132
-
### What's the difference between Patreon and OpenCollective?
132
+
### What's the difference between Patreon and OpenCollective funding?
133
133
134
134
Funds donated via Patreon go directly to support Evan You's full-time work on Vue.js. Funds donated via OpenCollective are managed with transparent expenses and will be used for compensating work and expenses for core team members or sponsoring community events. Your name/logo will receive proper recognition and exposure by donating on either platform.
0 commit comments