build: update configs, add HTML validation
This commit is contained in:
parent
0167884748
commit
ac960cf8b4
8 changed files with 2037 additions and 22 deletions
28
package.json
28
package.json
|
@ -5,19 +5,24 @@
|
|||
"scripts": {
|
||||
"precommit": "npm run lint-staged",
|
||||
"dev": "snap run hugo serve",
|
||||
"lint": "npm run lint:css; npm run lint:md; npm run lint:html; npm run lint:json",
|
||||
"lint:fix": "npm run lint:css:fix; npm run lint:md:fix; npm run lint:html:fix; npm run lint:json:fix",
|
||||
"build": "rm -rf ./public/ && snap run hugo --environment production && npm run format:html:fix -- ./public ",
|
||||
"lint": "npm-run-all2 lint:*",
|
||||
"lint:fix": "npm-run-all2 lint:*:fix",
|
||||
"lint:css": "stylelint \"./assets/css/**/*.scss\" --cache --cache-location .cache/ .stylelintcache",
|
||||
"lint:css:fix": "npm run lint:css -- --fix",
|
||||
"lint:js": "eslint \"./assets/js/*.js\" \"./content/**/*.js\"",
|
||||
"format:html": "prettier --parser html --check \"public/**/*.{htm,html}\"",
|
||||
"format:html:fix": "npm run format:html -- --write",
|
||||
"format:md": "prettier --parser markdown \"*/**/*.md\"",
|
||||
"format:md:fix": "npm run format:md -- --write",
|
||||
"lint:md": "markdownlint --rules sentences-per-line \"*/**/*.md\"",
|
||||
"lint:js:fix": "eslint \"./assets/js/*.js\" \"./content/**/*.js\" --fix",
|
||||
"lint:md": "markdownlint --rules sentences-per-line .",
|
||||
"lint:md:fix": "npm run lint:md -- --fix",
|
||||
"lint:json": "jsonlint ./**/*.json -s",
|
||||
"lint:json:fix": "npm run lint:json -- -i"
|
||||
"lint:html": "npm run build && htmlhint ./public; html-validate ./public",
|
||||
"lint:json": "jsonlint . -s",
|
||||
"lint:json:fix": "npm run lint:json -- -i",
|
||||
"format": "npm-run-all2 format:*",
|
||||
"format:fix": "npm-run-all format:*:fix",
|
||||
"format:html": "prettier --parser html --check .",
|
||||
"format:html:fix": "npm run format:html -- --write",
|
||||
"format:md": "prettier --parser markdown .",
|
||||
"format:md:fix": "npm run format:md -- --write"
|
||||
},
|
||||
"lint-staged": {
|
||||
"*.s?[ca]ss": [
|
||||
|
@ -47,12 +52,17 @@
|
|||
},
|
||||
"devDependencies": {
|
||||
"eslint": "^9.17.0",
|
||||
"eslint-config-prettier": "^9.1.0",
|
||||
"html-validate": "^9.1.0",
|
||||
"htmlhint": "^1.1.4",
|
||||
"husky": "^9.1.7",
|
||||
"jsonlint": "^1.6.3",
|
||||
"lint-staged": "^15.3.0",
|
||||
"markdownlint": "^0.37.3",
|
||||
"markdownlint-cli": "^0.43.0",
|
||||
"npm-run-all2": "^7.0.2",
|
||||
"prettier": "^3.4.2",
|
||||
"prettier-plugin-go-template": "^0.0.15",
|
||||
"sentences-per-line": "^0.3.0",
|
||||
"stylelint": "^16.12.0",
|
||||
"stylelint-config-standard-scss": "^14.0.0",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue