Skip to content
This repository has been archived by the owner on Jan 8, 2020. It is now read-only.

Commit

Permalink
Merge remote-tracking branch 'upstream/v2' from https://github.com/lo…
Browse files Browse the repository at this point in the history
…garetm/vee-validate

* upstream/v2: (689 commits)
  fix: update v3 links and repo links closes logaretm#2467
  chore: add v3 docs link
  docs: add note for read me
  Added missing changes flag in FieldFlags definition (logaretm#2218)
  docs: uneeded document about escaping regex
  docs: fix the regex example
  chore: bump to 2.2.15
  revert: logaretm#2185 closes logaretm#2209
  chore: bump to 2.2.14
  chore: upgrade dependencies
  fix: mark vee-validate handlers so they get deduped
  Revert "fix: don't sync the value in an event handler closes logaretm#2185"
  chore: rm .DS_Store
  test: fix failing tests due to punctation
  test: fix failing tests
  Remove periods at end of validation messages (logaretm#2195)
  alpha_helper.js: regex for persian characters has been added (logaretm#2190)
  fix: don't sync the value in an event handler closes logaretm#2185
  fix: cleanup events before adding new ones
  Update displaying-errors.md (logaretm#2186)
  ...
  • Loading branch information
Álvaro Brey committed Jan 7, 2020
2 parents 60702e1 + 67b9bb3 commit cbf94b7
Show file tree
Hide file tree
Showing 483 changed files with 27,340 additions and 40,285 deletions.
9 changes: 5 additions & 4 deletions .babelrc
@@ -1,8 +1,9 @@
{
"presets": ["env"],
"presets": [
"@babel/env"
],
"plugins": [
"transform-async-to-generator",
"transform-flow-strip-types",
"transform-object-rest-spread"
"@babel/plugin-transform-flow-strip-types",
"@babel/plugin-transform-runtime"
]
}
10 changes: 7 additions & 3 deletions .eslintrc.json
Expand Up @@ -2,14 +2,17 @@
"env": {
"browser": true,
"commonjs": true,
"es6": true
"es6": true,
"jest/globals": true
},
"extends": [
"standard",
"plugin:flowtype/recommended"
"plugin:flowtype/recommended",
"plugin:jest/recommended"
],
"plugins": [
"flowtype"
"flowtype",
"jest"
],
"rules": {
"indent": [
Expand All @@ -25,6 +28,7 @@
"always"
],
"comma-dangle": 0,
"no-console": "error",
"space-unary-ops": 0,
"import/no-extraneous-dependencies": 0,
"no-new": 0,
Expand Down
8 changes: 0 additions & 8 deletions .github/ISSUE_TEMPLATE.md

This file was deleted.

39 changes: 39 additions & 0 deletions .github/ISSUE_TEMPLATE/Bug_report.md
@@ -0,0 +1,39 @@
---
name: 🐛 Bug report
about: Create a report to help us improve.
---

**Versions**

- vee-validate: 2.#.#
- vue: 2.#.#

**Describe the bug**
A clear and concise description of what the bug is.

**To reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Expected behavior**
A clear and concise description of what you expected to happen.

**Demo link**
If applicable, add a minimal demo link to help explain your problem. You can use [JSFiddle](https://jsfiddle.net/) or [Codesandbox](https://codesandbox.io/).

**Desktop (please complete the following information):**
- OS: [e.g. iOS]
- Browser [e.g. chrome, safari]
- Version [e.g. 22]

**Smartphone (please complete the following information):**
- Device: [e.g. iPhone6]
- OS: [e.g. iOS8.1]
- Browser [e.g. stock browser, safari]
- Version [e.g. 22]

**Additional context**
Add any other context about the problem here.
16 changes: 16 additions & 0 deletions .github/ISSUE_TEMPLATE/Feature_request.md
@@ -0,0 +1,16 @@
---
name: 🚀 Feature request
about: Suggest an idea for this project.
---

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
21 changes: 21 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
@@ -0,0 +1,21 @@
🔎 __Overview__

Explain the premise for adding this PR and why is it important.

Ex (Feat):
> This PR {adds/fixes/improves} the {feature/bug/something}.
Ex (Locale):
> This PR changes the {locale} messages style because {reason}
🤓 __Code snippets/examples (if applicable)__

```js
// some code
```

__Issues affected__

list of issues formatted like this:

> closes #{issue id}
4 changes: 4 additions & 0 deletions .gitignore
Expand Up @@ -6,3 +6,7 @@ coverage
.vscode
.vs
yarn-error.log
dist
.DS_Store
.AppleDouble
.LSOverride
8 changes: 5 additions & 3 deletions .travis.yml
@@ -1,10 +1,12 @@
language: node_js
node_js:
- '8'
- '10'
before_install:
- curl -o- -L https://yarnpkg.com/install.sh | bash
- export PATH="$HOME/.yarn/bin:$PATH"
install:
- npm install -g yarn
- npm install -g codecov
- yarn
after_success:
- npm run cover
- yarn cover --maxWorkers=$(nproc)
- bash <(curl -s https://codecov.io/bash)
103 changes: 62 additions & 41 deletions CONTRIBUTING.md
Expand Up @@ -4,77 +4,98 @@ First of all, thanks for taking interest into contributing to this repository, b

### Getting Started

Clone the repo
Fork the repository, or clone it:

`git clone https://github.com/baianat/vee-validate.git`

Install dependencies

```
npm install
```bash
git clone https://github.com/logaretm/vee-validate.git
```

or
Install dependencies using [yarn](https://yarnpkg.com)

```
```bash
yarn
```

Check the `scripts` section of `package.json` for any npm scripts that might find useful.

### Folder Structure

As you can see we have:

- `src` contains the working code for the repository:
- `plugins`: contains any sort of add-on behavior and rules, that may or not may be available at all times.
- `rules`: contains validation rules that are available to the validator instances.
- `utils`: contains small utility functions.
- `dist` contains the unminified and the minified build of the repository.
- `docs` contains the src and built files for the documentation.
- `locale` contains the localized messages files.
- `tests` contains the test files for the project, it uses [jest](https://github.com/facebook/jest) for testing. it contains a similar folder structure as the `src` folder.
- `core`: contains files that are the
- `rules`: contains validation rules that are available to the validator instances.
- `utils`: contains commonly used utility functions.
- `dist`: contains the unminified and the minified build of the repository.
- `docs`: contains the src and built files for the documentation, we use [vuepress](https://vuepress.vuejs.org/) to generate the docs content.
- `locale`: contains the localized messages files.
- `tests`: contains the test files for the project, it uses [jest](https://github.com/facebook/jest) for testing. it contains a similar folder structure as the `src` folder.
- `scripts`: has all our custom scripts used to bundle the project, release the docs and localization files generation.

### Issues

When creating issues, please provide as much details as possible. A clear explanation on the issue and a reliable production example can help us greatly in improving this project. Your issue may get closed if it cannot be easily reproduced so please provide a working example using either [Codesandbox](https://codesandbox.io/) or [jsfiddle](https://jsfiddle.net/). Your example should only focus on the issue, minimal and clearly produces the issue.

If your issue gets closed for not providing enough info or not responding to the maintainers' comments, do not consider it a hostile action. There are probably other issues that the maintainers are working on and must give priority to issues that are well investigated, you can always revisit the issue and address the reasons that it was closed and we will be happy to re-open it and address it properly. Sometimes a commit will close your issue without a response from the maintainers so make sure you read the issue timeline to prevent any misunderstandings.

### Code Style

The code style is enforced with `eslint` and is checked automatically whenever you commit. Any violation of the code style may prevent merging your contribution so make sure you follow it. And yes we love our semi-colons.

### Commit Style

Commit messages are enforced with `commitlint` which is configured to help you write a suitable commit message, the checks are run automatically when you commit.

### Contributing To The Docs

If you want to contribute to the docs you can find it in the `docs` folder.

Our docs require `./dist/vee-validate.esm` as dependency to run successfully in your local machine. You can generate this dependency by executing the following command from the root of the repository:

```bash
yarn build:esm
# or
npm run build:esm
```

And then you can run vuepress local dev server by running:

```bash
yarn docs:dev
# or
npm run docs:dev
```

### Pull Requests

- Respect the ESlint rules, but we are open to any suggestions or alterations.
- You don't have to build the library with each pull request, but you will if you plan to test it manually. No need to submit it in the PR to avoid unnecessary conflicts.
- Make sure you fill the PR template provided.
- PRs should have titles that are clear as possible.
- Make sure that your PR is up to date with the branch you are targeting, use git rebase for this.
- Make sure that your PR is up to date with the branch you are targeting, use `git rebase` for this.
- Unfinished/In-Progress PRs should have `[WIP]` prefix to them, and preferably a checklist for ongoing todos.
- Make sure to mention which issues are being fixed by the PR so they can be closed properly.
- Make sure to preview all pending PRs to make sure your work won't conflict with other ongoing pull-request.
- Coordinate with ongoing conflicting PRs' authors to make it easier to merge both your PRs.

### Source Code

Currently we are using ES2015 (ES6) for the source code, using buble and rollup to convert and bundle it to ES5, the available builds are: non-minified and minified and es6 build.

Also we are using ESlint for code style, with the standard config with few modifications, please respect them as much as you can.
Currently we are using ES2015 (ES6) for the source code, using buble and rollup to convert and bundle it to ES5, the available builds are: non-minified and minified and esm build.

### Testing

Each test file represents a unit test to the corresponding file in the src folder.

To run the tests:

`npm test`
```bash
yarn test
# or
npm run test
```

### Building

Use `npm run build` to build the project both minified and unminified versions.


### Issues

When creating issues, please provide as much details as possible. A clear explaination on the issue and a reliable production example can help us greatly in improving this project.

If your issue gets closed for not providing enough info or not responding to the maintainers' comments, do not consider it a hostile action. There are probably other issues that the maintainers are working on and must give priority to issues that are well investigated, you can always revisit the issue and address the reasons that it was closed and we will be happy to re-open it and address it properly.

To make sure your issues are addressed as fast as possible, follow the issue template and fill as much details as you can:

- Provide the versions that you encounter the issue with for `vue` and `vee-validate` and any other third party package that are involved.

- A clear details of what is happening and your comments on them.

- An example that demonstrates the issue clearly, you should make sure that it has no other issues except the one you are reporting.
Use this command to build all project bundles and localization files:

```bash
yarn build
# or
npm run build
```

0 comments on commit cbf94b7

Please sign in to comment.