trying eslint for linting the little JS code
This commit is contained in:
parent
7b092aa8c4
commit
822af715a3
@ -14,7 +14,8 @@ steps:
|
||||
image: golangci/golangci-lint:v1.42.0
|
||||
commands:
|
||||
- make install-tools
|
||||
- make lint
|
||||
- make lint-go
|
||||
- make lint-buf
|
||||
depends_on:
|
||||
- tags
|
||||
|
||||
|
6
.eslintrc.json
Normal file
6
.eslintrc.json
Normal file
@ -0,0 +1,6 @@
|
||||
{
|
||||
"env": {
|
||||
"browser": true
|
||||
},
|
||||
"extends": ["eslint:recommended", "prettier"]
|
||||
}
|
1
.prettierrc.json
Normal file
1
.prettierrc.json
Normal file
@ -0,0 +1 @@
|
||||
{}
|
12
Makefile
12
Makefile
@ -11,10 +11,20 @@ generate:
|
||||
go generate
|
||||
|
||||
.PHONY: lint
|
||||
lint:
|
||||
lint: lint-go lint-buf lint-js
|
||||
|
||||
.PHONY: lint-go
|
||||
lint-go:
|
||||
golangci-lint run --timeout 10m --enable-all --disable=exhaustivestruct
|
||||
|
||||
.PHONY: lint-buf
|
||||
lint-buf:
|
||||
buf lint -v
|
||||
|
||||
.PHONY: lint-js
|
||||
lint-js:
|
||||
eslint assets/web/files/**.js
|
||||
|
||||
.PHONY: test
|
||||
test:
|
||||
go test -v -race -cover ./...
|
||||
|
Loading…
Reference in New Issue
Block a user