2021-04-15 03:06:08 +01:00
{
"scripts" : {
2021-04-24 10:29:58 +01:00
"cm" : "cz" ,
2021-04-15 03:20:58 +01:00
"format" : "npm run format:js" ,
"format:fix" : "npm run format:js:fix" ,
2021-04-24 09:16:58 +01:00
"format:js" : "prettier --config .prettierrc './src/**/*.js'" ,
2021-04-15 03:20:58 +01:00
"format:js:fix" : "npm run format:js -- --write" ,
2021-04-24 10:29:58 +01:00
"lint" : "npm run lint:js && npm run lint:css && npm run lint:md" ,
"lint:fix" : "npm run lint:js:fix && npm run lint:css:fix && npm run lint:md:fix" ,
"lint:php" : "composer run lint:php" ,
"lint:php:fix" : "composer run lint:php:fix" ,
2021-04-24 09:16:58 +01:00
"lint:js" : "eslint \"./src/**/*.js\"" ,
2021-04-15 03:06:08 +01:00
"lint:js:fix" : "npm run lint:js -- --fix" ,
2021-04-24 09:16:58 +01:00
"lint:css" : "stylelint \"./src/**/*.css\"" ,
2021-04-24 10:29:58 +01:00
"lint:css:fix" : "npm run lint:css -- --fix" ,
"lint:md" : "markdownlint '*.md'" ,
2021-04-24 10:58:25 +01:00
"lint:md:fix" : "npm run lint:md -- --fix" ,
"minify" : "npm run minify:css && npm run minify:js" ,
"minify:css" : "for f in ./tmp/css/*.css; do npx minify $f > ./dist/css/$(basename $f .css).min.css; done" ,
"minify:js" : "for f in ./src/js/wysiwyg-editor.js; do npx minify $f > ./dist/js/$(basename $f .js).min.js; done"
2021-04-24 10:29:58 +01:00
} ,
"husky" : {
"hooks" : {
"pre-commit" : "lint-staged" ,
2021-04-24 10:31:52 +01:00
"pre-push" : "composer run docs && git add docs && git commit -m \"docs: update documentation\" --no-verify"
2021-04-24 10:29:58 +01:00
}
} ,
"lint-staged" : {
"*.php" : [
"composer run lint:php"
] ,
"*.js" : [
"npm run format:js:fix" ,
"npm run lint:js"
] ,
"*.(sa|sc|c)ss" : [
"npm run lint:css"
] ,
"*.md" : [
"npm run lint:md"
]
2021-04-15 03:06:08 +01:00
} ,
"devDependencies" : {
2021-04-24 10:29:58 +01:00
"cz-conventional-changelog" : "^3.3.0" ,
2021-04-15 03:06:08 +01:00
"eslint" : "^7.24.0" ,
"eslint-config-prettier" : "^8.2.0" ,
"eslint-config-wordpress" : "^2.0.0" ,
"eslint-plugin-prettier" : "^3.4.0" ,
2021-04-24 10:29:58 +01:00
"husky" : "^4.3.8" ,
"lint-staged" : "^10.5.4" ,
"markdownlint-cli" : "^0.27.1" ,
2021-04-24 10:58:25 +01:00
"minify" : "^7.0.1" ,
2021-04-15 03:06:08 +01:00
"prettier" : "^2.2.1" ,
"stylelint" : "^13.12.0" ,
"stylelint-config-wordpress" : "^17.0.0"
2021-04-20 03:48:16 +02:00
} ,
2021-04-24 10:29:58 +01:00
"license" : "GPL-3.0" ,
"config" : {
"commitizen" : {
"path" : "./node_modules/cz-conventional-changelog"
}
}
2021-04-24 09:16:58 +01:00
}