Skip to content

Commit

Permalink
chore!: prepare structure for Nuxt 3 support
Browse files Browse the repository at this point in the history
  • Loading branch information
lihbr committed Dec 6, 2021
1 parent afa7116 commit 4d59509
Show file tree
Hide file tree
Showing 41 changed files with 5,147 additions and 9,009 deletions.
7 changes: 5 additions & 2 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,15 @@
root = true

[*]
indent_size = 2
indent_style = space
indent_style = tab
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true

[*.md]
trim_trailing_whitespace = false

[*.yml]
indent_style = space
indent_size = 2
44 changes: 37 additions & 7 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,11 +1,41 @@
node_modules
# .gitignore copy

# custom
dist
.nuxt
coverage
*.log*
examples/**/package-lock.json

# os
.DS_Store
.code
*.iml
._*

# node
logs
*.log
node_modules

# yarn
yarn-debug.log*
yarn-error.log*
lerna-debug.log*
.yarn-integrity

# npm
npm-debug.log*
package-lock.json
templates/*
sw.js

# tests
coverage
.eslintcache
.nyc_output

# .env
.env
.env.test
.env*.local

# vscode
.vscode/*
!.vscode/tasks.json
!.vscode/launch.json
*.code-workspace
37 changes: 37 additions & 0 deletions .eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
module.exports = {
root: true,
env: {
browser: true,
node: true,
},
parserOptions: {
parser: "@typescript-eslint/parser",
ecmaVersion: 2020,
},
extends: [
"plugin:@typescript-eslint/eslint-recommended",
"plugin:@typescript-eslint/recommended",
"plugin:prettier/recommended",
],
plugins: ["eslint-plugin-tsdoc"],
rules: {
"no-console": ["warn", { allow: ["info", "warn", "error"] }],
"no-debugger": "warn",
"no-undef": "off",
curly: "error",
"prefer-const": "error",
"padding-line-between-statements": [
"error",
{ blankLine: "always", prev: "*", next: "return" },
],
"@typescript-eslint/no-unused-vars": [
"error",
{
argsIgnorePattern: "^_",
varsIgnorePattern: "^_",
},
],
"@typescript-eslint/no-var-requires": "off",
"tsdoc/syntax": "warn",
},
};
3 changes: 0 additions & 3 deletions .eslintrc.js

This file was deleted.

6 changes: 3 additions & 3 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
---
name: 🚨 Bug report
about: Report a bug report to help us improve the module.
about: Report a bug report to help improve the package.
title: ""
labels: "bug"
assignees: ""
---

<!-- 💙 Thanks for your time to make this module better with your feedback 💙
<!-- 💙 Thanks for your time to make this package better with your feedback 💙
**IMPORTANT** Before reporting a bug please make sure that you have read through the documentation:
- https://prismic.nuxtjs.org
- https://prismic.io/docs
👍 A properly detailed bug report can save a LOT of time and help fixing issues as soon as possible.
-->
Expand Down
8 changes: 4 additions & 4 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
blank_issues_enabled: false
contact_links:
- name: Nuxt Community Discord
- name: 🎙 Nuxt Community Discord
url: https://discord.nuxtjs.org
about: Consider asking questions about the module here.
- name: Prismic Community Forum
about: Nuxt Community Discord is a nice place to ask your questions and get live support by the community!
- name: 👪 Prismic Community Forum
url: https://community.prismic.io
about: Please use Prismic community forum for issues or questions directly related to Prismic.
about: Ask a question about the package or raise an issue directly related to Prismic. You will usually get support there more quickly!
4 changes: 2 additions & 2 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
---
name: 🙋‍♀️ Feature request
about: Suggest an idea or enhancement for the module.
about: Suggest an idea or enhancement for the package.
title: ""
labels: "enhancement"
assignees: ""
---

<!-- 💙 Thanks for your time to make this module better with your feedback 💙 -->
<!-- 💙 Thanks for your time to make this package better with your feedback 💙 -->

### Is your feature request related to a problem? Please describe.

Expand Down
8 changes: 4 additions & 4 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

<!--- What types of changes does your code introduce? Put an `x` in all the boxes that apply: -->

- [ ] Chore (a non-breaking change which is related to package maintenance)
- [ ] Bug fix (a non-breaking change which fixes an issue)
- [ ] New feature (a non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
Expand All @@ -17,11 +18,10 @@
## Checklist:

<!--- Put an `x` in all the boxes that apply. -->
<!--- If your change requires a documentation PR, please link it appropriately -->
<!--- If you're unsure about any of these, don't hesitate to ask. We're here to help! -->

- [ ] My change requires a change to the documentation.
- [ ] I have updated the documentation accordingly. (PR: #)
- [ ] My change requires an update to the official documentation.
- [ ] All [TSDoc](https://tsdoc.org) comments are up-to-date and new ones have been added where necessary.
- [ ] All new and existing tests are passing.

<!--- A cute animal picture is welcome to close your PR! -->
<!--- A cute animal (or car) picture is welcome to close your PR! -->
19 changes: 11 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,31 +15,34 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
node: [14]
node: [16]

steps:
- uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}

- name: checkout
- name: Checkout
uses: actions/checkout@master

- name: cache node_modules
- name: Cache node_modules
uses: actions/cache@v2
with:
path: node_modules
key: ${{ matrix.os }}-node-v${{ matrix.node }}-deps-${{ hashFiles(format('{0}{1}', github.workspace, '/yarn.lock')) }}
key: ${{ matrix.os }}-node-v${{ matrix.node }}-deps-${{ hashFiles(format('{0}{1}', github.workspace, '/package-lock.json')) }}

- name: Install dependencies
if: steps.cache.outputs.cache-hit != 'true'
run: yarn
run: npm ci

- name: Lint
run: yarn lint
run: npm run lint

- name: Test
run: yarn test
- name: Unit
run: npm run unit

- name: Build
run: npm run build

- name: Coverage
uses: codecov/codecov-action@v1
42 changes: 36 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,39 @@
node_modules
*.iml
.idea
*.log*
# custom
dist
.nuxt
.vscode
examples/**/package-lock.json

# os
.DS_Store
._*

# node
logs
*.log
node_modules

# yarn
yarn-debug.log*
yarn-error.log*
lerna-debug.log*
.yarn-integrity

# npm
npm-debug.log*
package-lock.json

# tests
coverage
dist
.eslintcache
.nyc_output

# .env
.env
.env.test
.env*.local

# vscode
.vscode/*
!.vscode/tasks.json
!.vscode/launch.json
*.code-workspace
41 changes: 41 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# .gitignore copy

# custom
dist
.nuxt
examples/**/package-lock.json

# os
.DS_Store
._*

# node
logs
*.log
node_modules

# yarn
yarn-debug.log*
yarn-error.log*
lerna-debug.log*
.yarn-integrity

# npm
npm-debug.log*
package-lock.json

# tests
coverage
.eslintcache
.nyc_output

# .env
.env
.env.test
.env*.local

# vscode
.vscode/*
!.vscode/tasks.json
!.vscode/launch.json
*.code-workspace
21 changes: 21 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"plugins": ["prettier-plugin-jsdoc"],
"jsdocSeparateReturnsFromParam": true,
"jsdocSeparateTagGroups": true,
"jsdocSingleLineComment": false,
"tsdoc": true,
"printWidth": 80,
"useTabs": true,
"semi": true,
"singleQuote": false,
"quoteProps": "as-needed",
"jsxSingleQuote": false,
"trailingComma": "all",
"bracketSpacing": true,
"bracketSameLine": false,
"arrowParens": "always",
"requirePragma": false,
"insertPragma": false,
"htmlWhitespaceSensitivity": "css",
"endOfLine": "lf"
}
Loading

0 comments on commit 4d59509

Please sign in to comment.