trying eslint for linting the little JS code

main
Marvin Preuss 3 years ago
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

@ -0,0 +1,6 @@
{
"env": {
"browser": true
},
"extends": ["eslint:recommended", "prettier"]
}

@ -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 ./...

@ -11,3 +11,4 @@ lint:
- RPC_REQUEST_STANDARD_NAME
- RPC_RESPONSE_STANDARD_NAME
- RPC_REQUEST_RESPONSE_UNIQUE
- PACKAGE_VERSION_SUFFIX

Loading…
Cancel
Save