Skip to content

Commit 71f11fa

Browse files
committed
Initial commit
0 parents  commit 71f11fa

17 files changed

+5915
-0
lines changed

.editorconfig

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
root = true
2+
3+
[*]
4+
indent_style = space
5+
end_of_line = lf
6+
charset = utf-8
7+
trim_trailing_whitespace = true
8+
insert_final_newline = true
9+
max_line_length = 160
10+
indent_size = 2
11+
12+
[*.md]
13+
trim_trailing_whitespace = false

.github/CODE_OF_CONDUCT.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# Code Of Conduct
2+
3+
## Our Pledge
4+
5+
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, political party, or sexual identity and orientation. Note, however, that religion, political party, or other ideological affiliation provide no exemptions for the behavior we outline as unacceptable in this Code of Conduct.
6+
7+
## Our Standards
8+
9+
Examples of behavior that contributes to creating a positive environment include:
10+
11+
- Using welcoming and inclusive language
12+
- Being respectful of differing viewpoints and experiences
13+
- Gracefully accepting constructive criticism
14+
- Focusing on what is best for the community
15+
- Showing empathy towards other community members
16+
17+
Examples of unacceptable behavior by participants include:
18+
19+
- The use of sexualized language or imagery and unwelcome sexual attention or advances
20+
- Trolling, insulting/derogatory comments, and personal or political attacks
21+
- Public or private harassment
22+
- Publishing others' private information, such as a physical or electronic address, without explicit permission
23+
- Other conduct which could reasonably be considered inappropriate in a professional setting
24+
25+
## Our Responsibilities
26+
27+
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
28+
29+
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
30+
31+
## Scope
32+
33+
This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
34+
35+
## Enforcement
36+
37+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team by sending an e-mail to [email protected]. All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
38+
39+
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
40+
41+
## Attribution
42+
43+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
44+
45+
[homepage]: https://www.contributor-covenant.org

.github/CONTRIBUTING.md

Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
# Contributing Guide
2+
3+
- [General Guidelines](#general-guidelines)
4+
- [Issue Reporting Guidelines](#issue-reporting-guidelines)
5+
- [Pull Request Guidelines](#pull-request-guidelines)
6+
- [Work Step Example](#work-step-example)
7+
- [Development Setup](#development-setup)
8+
- [Commonly used NPM scripts](#commonly-used-npm-scripts)
9+
10+
## General Guidelines
11+
12+
English is used as the common language to communicate with Maintainers. If description of issue / PR are written in
13+
non-English languages, those may be closed.
14+
15+
## Issue Reporting Guidelines
16+
17+
- Try to search for your issue, it may have already been answered or even fixed in the development branch.
18+
19+
- Check if the issue is reproducible with the latest stable version of Vue. If you are using a pre-release, please
20+
indicate the specific version you are using.
21+
22+
- It is **required** that you clearly describe the steps necessary to reproduce the issue you are running into. Issues with no clear reproduction steps may be closed. If an issue labeled "need repro" receives no further input from the issue author for more than 5 days, it will be closed.
23+
24+
- For bugs that involves build setups, you can create a reproduction repository with steps in the `README` file.
25+
26+
- 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.
27+
28+
## Pull Request Guidelines
29+
30+
- Make sure `pnpm test` passes. (see [development setup](#development-setup))
31+
32+
- If adding new feature:
33+
34+
- Add accompanying test case.
35+
36+
- Provide convincing reason to add this feature. Ideally you should open a suggestion issue first to discuss with the Maintainers/Community before working on it.
37+
38+
- If fixing a bug:
39+
- Provide detailed description of the bug in the PR. Live demo preferred.
40+
41+
- Add appropriate test coverage if applicable.
42+
43+
### Work Step Example
44+
45+
- Fork the repository
46+
- Create your topic branch from `main`:
47+
48+
```shell
49+
git branch my-new-topic origin/main
50+
```
51+
52+
- Write new code and relevant tests
53+
- Run test and lint scripts
54+
- Commit your changes: `git commit -am 'add feature X'`
55+
- Push to the branch: `git push origin my-new-topic`
56+
- Submit a pull request to `main` branch of repository
57+
58+
## Development Setup
59+
60+
You will need [Node.js][#node] and [`pnpm`][#pnpm] and the code base is mainly written in [TypeScript][#ts]
61+
62+
After cloning the repo, run:
63+
64+
```shell
65+
pnpm install
66+
```
67+
68+
### Commonly used NPM scripts
69+
70+
```shell
71+
# lint source codes
72+
$ pnpm lint
73+
74+
# watch and run tests
75+
$ pnpm test
76+
77+
# build all dist files
78+
$ pnpm build
79+
```
80+
81+
There are some other scripts available in the `scripts` section of the `package.json` file.
82+
83+
[#pnpm]: https://pnpm.io
84+
[#node]: http://nodejs.org
85+
[#ts]: https://www.typescriptlang.org

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: ''
5+
labels: ''
6+
assignees: ''
7+
8+
---
9+
10+
**Describe the bug**
11+
A clear and concise description of what the bug is.
12+
13+
**To Reproduce**
14+
Steps to reproduce the behavior:
15+
1. Go to '...'
16+
2. Click on '....'
17+
3. Scroll down to '....'
18+
4. See error
19+
20+
**Expected behavior**
21+
A clear and concise description of what you expected to happen.
22+
23+
**Screenshots**
24+
If applicable, add screenshots to help explain your problem.
25+
26+
**Desktop (please complete the following information):**
27+
- OS: [e.g. iOS]
28+
- Browser [e.g. chrome, safari]
29+
- Version [e.g. 22]
30+
31+
**Smartphone (please complete the following information):**
32+
- Device: [e.g. iPhone6]
33+
- OS: [e.g. iOS8.1]
34+
- Browser [e.g. stock browser, safari]
35+
- Version [e.g. 22]
36+
37+
**Additional context**
38+
Add any other context about the problem here.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
name: Feature request
3+
about: Suggest an idea for this project
4+
title: ''
5+
labels: ''
6+
assignees: ''
7+
8+
---
9+
10+
**Is your feature request related to a problem? Please describe.**
11+
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
12+
13+
**Describe the solution you'd like**
14+
A clear and concise description of what you want to happen.
15+
16+
**Describe alternatives you've considered**
17+
A clear and concise description of any alternative solutions or features you've considered.
18+
19+
**Additional context**
20+
Add any other context or screenshots about the feature request here.

.github/workflows/test.yml

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: Test
2+
on:
3+
push:
4+
branches:
5+
- main
6+
pull_request:
7+
branches:
8+
- main
9+
env:
10+
CI: true
11+
12+
jobs:
13+
test:
14+
name: 'Test on Node.js ${{ matrix.node }} OS: ${{ matrix.os }}'
15+
runs-on: ${{ matrix.os }}
16+
strategy:
17+
matrix:
18+
os: [ubuntu-latest, windows-latest]
19+
node: [16, 17]
20+
steps:
21+
- name: Checkout
22+
uses: actions/[email protected]
23+
- name: Setup Node.js ${{ matrix.node }}
24+
uses: actions/[email protected]
25+
with:
26+
node-version: ${{ matrix.node }}
27+
- uses: pnpm/[email protected]
28+
with:
29+
version: 7.x.x
30+
run_install: true
31+
32+
- name: Test
33+
run: pnpm test -- --coverage
34+
35+
- name: Upload code coverage
36+
uses: codecov/codecov-action@v3
37+
with:
38+
flags: vue-${{matrix.vue}}
39+
40+
lint:
41+
runs-on: ubuntu-latest
42+
name: Lint source code
43+
steps:
44+
- name: Checkout
45+
uses: actions/[email protected]
46+
- name: Setup Node.js
47+
uses: actions/[email protected]
48+
- uses: pnpm/[email protected]
49+
with:
50+
version: 7.x.x
51+
run_install: true
52+
53+
- name: Lint
54+
run: pnpm lint

.gitignore

Lines changed: 132 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,132 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
yarn-debug.log*
6+
yarn-error.log*
7+
lerna-debug.log*
8+
.pnpm-debug.log*
9+
10+
# Diagnostic reports (https://nodejs.org/api/report.html)
11+
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
12+
13+
# Runtime data
14+
pids
15+
*.pid
16+
*.seed
17+
*.pid.lock
18+
19+
# Directory for instrumented libs generated by jscoverage/JSCover
20+
lib-cov
21+
22+
# Coverage directory used by tools like istanbul
23+
coverage
24+
*.lcov
25+
26+
# nyc test coverage
27+
.nyc_output
28+
29+
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
30+
.grunt
31+
32+
# Bower dependency directory (https://bower.io/)
33+
bower_components
34+
35+
# node-waf configuration
36+
.lock-wscript
37+
38+
# Compiled binary addons (https://nodejs.org/api/addons.html)
39+
build/Release
40+
41+
# Dependency directories
42+
node_modules/
43+
jspm_packages/
44+
45+
# Snowpack dependency directory (https://snowpack.dev/)
46+
web_modules/
47+
48+
# TypeScript cache
49+
*.tsbuildinfo
50+
51+
# Optional npm cache directory
52+
.npm
53+
54+
# Optional eslint cache
55+
.eslintcache
56+
57+
# Optional stylelint cache
58+
.stylelintcache
59+
60+
# Microbundle cache
61+
.rpt2_cache/
62+
.rts2_cache_cjs/
63+
.rts2_cache_es/
64+
.rts2_cache_umd/
65+
66+
# Optional REPL history
67+
.node_repl_history
68+
69+
# Output of 'npm pack'
70+
*.tgz
71+
72+
# Yarn Integrity file
73+
.yarn-integrity
74+
75+
# dotenv environment variable files
76+
.env
77+
.env.development.local
78+
.env.test.local
79+
.env.production.local
80+
.env.local
81+
82+
# parcel-bundler cache (https://parceljs.org/)
83+
.cache
84+
.parcel-cache
85+
86+
# Next.js build output
87+
.next
88+
out
89+
90+
# Nuxt.js build / generate output
91+
.nuxt
92+
dist
93+
94+
# Gatsby files
95+
.cache/
96+
# Comment in the public line in if your project uses Gatsby and not Next.js
97+
# https://nextjs.org/blog/next-9-1#public-directory-support
98+
# public
99+
100+
# vuepress build output
101+
.vuepress/dist
102+
103+
# vuepress v2.x temp and cache directory
104+
.temp
105+
.cache
106+
107+
# Docusaurus cache and generated files
108+
.docusaurus
109+
110+
# Serverless directories
111+
.serverless/
112+
113+
# FuseBox cache
114+
.fusebox/
115+
116+
# DynamoDB Local files
117+
.dynamodb/
118+
119+
# TernJS port file
120+
.tern-port
121+
122+
# Stores VSCode versions used for testing VSCode extensions
123+
.vscode-test
124+
125+
# yarn v2
126+
.yarn/cache
127+
.yarn/unplugged
128+
.yarn/build-state.yml
129+
.yarn/install-state.gz
130+
.pnp.*
131+
132+
.idea/

.husky/pre-commit

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/usr/bin/env sh
2+
. "$(dirname -- "$0")/_/husky.sh"
3+
4+
pnpm lint-staged
5+

0 commit comments

Comments
 (0)