Skip to content

v2.1.0 #4

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 14 commits into from
May 2, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 1 addition & 9 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,6 @@ end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true

[*.{yml,yaml,css,scss}]
[*.{json,html,yml,yaml,css,scss}]
indent_style = space
indent_size = 2

[*rc.json]
indent_style = space
indent_size = 4

[{*package.json,tsconfig.json}]
indent_style = space
indent_size = 2
5 changes: 5 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
*/node_modules/
/src/serviceWorker.ts
lint
start
lib
157 changes: 157 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,157 @@
function* range(min, max) {
for (let num = min; num < max; num++) {
yield num
}
}

module.exports = {
env: {
es2021: true,
node: true,
},
extends: ["eslint:recommended", "plugin:@typescript-eslint/eslint-recommended"],
parser: "@typescript-eslint/parser",
globals: {
Atomics: "readonly",
SharedArrayBuffer: "readonly",
},
parserOptions: {
ecmaVersion: 2021,
sourceType: "module",
project: ["./tsconfig.json"],
},
plugins: ["@typescript-eslint", "prefer-arrow"],
rules: {
// General ESLint rules
"arrow-body-style": ["warn", "as-needed"],
"default-case-last": "warn",
"dot-location": ["warn", "property"],
eqeqeq: "error",
"id-length": ["error", {exceptions: ["_", "$"]}],
"max-len": "off",
"max-lines": ["warn", 500],
"max-statements": ["warn", {max: 25}],
"no-else-return": "warn",
"no-empty": ["warn", {allowEmptyCatch: true}],
"no-extra-semi": "off",
"no-negated-condition": "warn",
"no-nested-ternary": "warn",
"no-unused-vars": "off",
"no-var": "warn",
"object-shorthand": "warn",
"one-var": ["warn", "never"],
"padding-line-between-statements": [
"warn",
{blankLine: "always", prev: "*", next: "return"},
{blankLine: "always", prev: ["const", "let", "var"], next: "*"},
{blankLine: "any", prev: ["const", "let", "var"], next: ["const", "let", "var"]},
{blankLine: "always", prev: "function", next: "*"},
],
"prefer-const": "warn",
"prefer-destructuring": [
"error",
{
array: false,
object: true,
},
],
"prefer-exponentiation-operator": "warn",
"prefer-object-spread": "warn",
"prefer-template": "warn",
"require-await": "warn",
"require-unicode-regexp": "warn",
"sort-imports": ["warn"],

// Typescript Rules
"@typescript-eslint/array-type": "warn",
"@typescript-eslint/consistent-indexed-object-style": ["warn", "index-signature"],
"@typescript-eslint/consistent-type-assertions": ["warn", {assertionStyle: "as"}],
"@typescript-eslint/member-ordering": "warn",
"@typescript-eslint/naming-convention": [
"error",
{
selector: "default",
format: ["camelCase"],
},
{
selector: "variableLike",
format: ["camelCase"],
leadingUnderscore: "allow",
},
{
selector: "memberLike",
modifiers: ["private"],
format: ["camelCase"],
leadingUnderscore: "require",
},
{
selector: "property",
modifiers: ["private"],
format: ["camelCase"],
leadingUnderscore: "require",
},
{
selector: "typeLike",
format: ["PascalCase"],
},
{
selector: "variable",
types: ["boolean"],
format: ["PascalCase"],
prefix: ["is", "should", "has", "can", "did", "will"],
},
{
selector: "parameter",
format: ["camelCase"],
leadingUnderscore: "allow",
},
{
selector: "property",
format: ["camelCase", "PascalCase", "snake_case", "UPPER_CASE"],
},
{
selector: "enumMember",
format: ["camelCase", "PascalCase", "snake_case", "UPPER_CASE"],
},
],
"@typescript-eslint/no-magic-numbers": [
"warn",
{
ignoreEnums: true,
ignoreNumericLiteralTypes: true,
ignoreReadonlyClassProperties: true,
ignoreArrayIndexes: true,
ignore: [...Array.from(range(-10, 11)), 16, 32, 64, 128, 256, 512],
},
],
"@typescript-eslint/no-unnecessary-boolean-literal-compare": "warn",
"@typescript-eslint/prefer-for-of": "warn",
"@typescript-eslint/prefer-function-type": "warn",
"@typescript-eslint/prefer-optional-chain": "warn",

// Typescript extension rules
"@typescript-eslint/default-param-last": "warn",
"@typescript-eslint/dot-notation": "warn",
"@typescript-eslint/lines-between-class-members": ["warn", "always"],
"@typescript-eslint/no-dupe-class-members": "warn",
"@typescript-eslint/no-duplicate-imports": "warn",
"@typescript-eslint/no-extra-semi": "off",
"@typescript-eslint/no-shadow": "warn",
"@typescript-eslint/no-unused-expressions": "warn",
"@typescript-eslint/no-unused-vars": "off",
"@typescript-eslint/no-unused-vars-experimental": "warn",
"@typescript-eslint/no-use-before-define": "warn",

// Preter arrow rules
"prefer-arrow-callback": "warn",
"prefer-arrow/prefer-arrow-functions": [
"warn",
{
disallowPrototype: true,
singleReturnOnly: false,
classPropertiesAllowed: true,
allowStandaloneDeclarations: false,
},
],
},
}
11 changes: 6 additions & 5 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,16 @@
name: Bug report
about: Create a report to help us improve
title: "[BUG] "
labels: ''
assignees: ''

labels: ""
assignees: ""
---

**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 '....'
Expand All @@ -24,8 +24,9 @@ A clear and concise description of what you expected to happen.
If applicable, add screenshots to help explain your problem.

**VSCode (please complete the following information):**
- OS: [e.g. iOS8.1]
- Version [e.g. 22]

- OS: [e.g. iOS8.1]
- Version [e.g. 22]

**Additional context**
Add any other context about the problem here.
5 changes: 2 additions & 3 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,8 @@
name: Feature request
about: Suggest an idea for this project
title: "[FEATURE] "
labels: ''
assignees: ''

labels: ""
assignees: ""
---

**Is your feature request related to a problem? Please describe.**
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: '14.x'
registry-url: 'https://registry.npmjs.org'
node-version: "14.x"
registry-url: "https://registry.npmjs.org"

- name: install deps
run: yarn install --frozen-lockfile
Expand Down
37 changes: 22 additions & 15 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,22 +7,29 @@ jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v2

- uses: actions/setup-node@v1
with:
node-version: '14.x'
registry-url: 'https://registry.npmjs.org'
- uses: actions/setup-node@v1
with:
node-version: "14.x"
registry-url: "https://registry.npmjs.org"

- name: install deps
run: yarn install --frozen-lockfile
- name: install deps
run: yarn install --frozen-lockfile

- name: build
run: yarn vsce package
- name: build
run: yarn vsce package

- name: Release
uses: softprops/action-gh-release@v1
with:
files: ./processing-vscode-*.vsix
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Release
uses: softprops/action-gh-release@v1
with:
files: ./processing-vscode-*.vsix
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Publish to marketplace
uses: lannonbr/vsce-action@master
with:
args: "publish -p $VSCE_TOKEN"
env:
VSCE_TOKEN: ${{ secrets.VSCE_TOKEN }}
9 changes: 8 additions & 1 deletion .prettierignore
Original file line number Diff line number Diff line change
@@ -1 +1,8 @@
*.json
src/documentation-data.json
*/node_modules/
build
.serverless
.vscode
lib/
tsconfig*.json
legacy
23 changes: 22 additions & 1 deletion .prettierrc.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,35 @@
# Normal Options
arrowParens: "always"
bracketSpacing: false
embeddedLanguageFormatting: "auto"
endOfLine: "lf"
htmlWhitespaceSensitivity: "strict"
jsxBracketSameLine: false
jsxSingleQuote: false
printWidth: 101
printWidth: 99
quoteProps: "as-needed"
semi: false
singleQuote: false
tabWidth: 4
trailingComma: "all"
useTabs: false

# JSDoc plugin
jsdocSpaces: 1
jsdocDescriptionWithDot: false
jsdocDescriptionTag: false
jsdocVerticalAlignment: false
jsdocKeepUnParseAbleExampleIndent: false
jsdocSingleLineComment: false
tsdoc: true

overrides:
- files:
- "*.html"
- "*.yml"
- "*.yaml"
- "*.json"
- "*.css"
- "*.scss"
options:
tabWidth: 2
Loading