Skip to content
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
2 changes: 2 additions & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
.cache
dist
6 changes: 3 additions & 3 deletions .lintstagedrc.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module.exports = {
'**/*.js': (files) => [`eslint --quiet --fix ${files.join(' ')}`],
'**/*.md': (files) => [`prettier --write ${files.join(' ')}`],
}
'**/*.js': (files) => [`eslint --quiet --fix ${files.join(' ')}`,`jest --passWithNoTests`],
'**/*.{md,js}': (files) => [`prettier --write ${files.join(' ')}`],
};
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
.cache
dist
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,13 @@
"postbuild:client": "mkdir -p dist/client/public && cp _redirects dist/client/_redirects && cp public/favicon.ico dist/client/favicon.ico && cp public/android-chrome-512x512.png dist/client/public/icon.png && cp -r .well-known dist/client/.well-known",
"build:server": "cp -r src/lambda/ dist/server",
"postbuild:server": "mkdir -p dist/server/server && mv dist/client/index.html dist/server/server/",
"lint": "eslint 'src/**/*.js' --quiet --fix",
"lint": "eslint . --quiet --fix",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

eslint can only parse .js(x)/.ts(x)-files, right? 🤔

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So we shouldn't run eslint on all files (.) then, right? 🤔

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Now there are only js files. The default extension for eslint is JavaScript file

"clean": "rimraf ./dist ./.cache",
"ci:lint": "eslint 'src/**/*.js' -c ./.eslintrc.js",
"ci:lint": "eslint .",
"ci:test": "jest --ci",
"test": "jest",
"test:watch": "jest --watch"
"test:watch": "jest --watch",
"prettier": "prettier . --write"
},
"dependencies": {
"codemirror": "5.53.2",
Expand Down