Skip to content
Draft
Show file tree
Hide file tree
Changes from 9 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
15 changes: 15 additions & 0 deletions .eslintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"env": {
"browser": true,
"es2021": true,
"node": true
},
"extends": "eslint:recommended",
"parserOptions": {
"ecmaVersion": "latest",
"sourceType": "module"
},
"rules": {

}
}
33 changes: 33 additions & 0 deletions .github/workflows/lint-js.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Lint JS


on:
pull_request:
branches: [gh-pages]
push:
branches: [gh-pages]

jobs:
build:
name: Lint JS
runs-on: ubuntu-latest

steps:
- name: Checkout Code
uses: actions/checkout@v3
with:
# Full git history is needed to get a proper list of changed files within `super-linter`
fetch-depth: 0

# Run Linter against code base #
- name: Lint JS
uses: github/super-linter@v5.0.0
env:
VALIDATE_ALL_CODEBASE: false
DEFAULT_BRANCH: gh-pages
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}


LINTER_RULES_PATH: /
JAVASCRIPT_ES_CONFIG_FILE: .eslintrc.json
VALIDATE_JAVASCRIPT_ES: true
6 changes: 6 additions & 0 deletions newEslintTest.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
const unusedVar = () => {
const foo = 1;
const bar = 2;
const baz = 3;
return bar;
}