lint md files

This commit is contained in:
Ulf Gebhardt 2023-11-17 18:20:42 +01:00
parent 9a0ae2ac83
commit ff49fe8340
Signed by: ulfgebhardt
GPG Key ID: DA6B843E748679C9
4 changed files with 9581 additions and 5 deletions

16
.remarkrc.json Normal file
View File

@ -0,0 +1,16 @@
{
"plugins": [
"remark-gfm",
"remark-preset-lint-consistent",
"remark-preset-lint-markdown-style-guide",
"remark-preset-lint-recommended",
[
"remark-lint-maximum-line-length",
false
],
[
"remark-lint-list-item-indent",
"space"
]
]
}

View File

@ -8,6 +8,7 @@
[![pinia][badge-pinia-img]][badge-pinia-href]
[![vue-i18n][badge-vue-i18n-img]][badge-vue-i18n-href]
[![eslint][badge-eslint-img]][badge-eslint-href]
[![remark-cli][badge-remark-cli-img]][badge-remark-cli-href]
[![vitest][badge-vitest-img]][badge-vitest-href]
[![storybook][badge-storybook-img]][badge-storybook-href]
[![vuepress][badge-vuepress-img]][badge-vuepress-href]
@ -20,7 +21,7 @@ To be able to build this project you need `nodejs`, `npm` and optional `docker`.
The project uses `vite` as builder, `vike` to do the SSR. The design framework is `vuetify` which requires the frontend framework `vue3`. For localization `vue-i18n` is used; Session storage is handled with `pinia`.
Testing is done with `eslint` and `vitest`.
Testing is done with `vitest` and code style is enforced with `eslint` and `remark-cli`.
This projects utilizes `storybook` to develop frontend components and `vuepress` for static documentation generation.
@ -38,6 +39,8 @@ The following commands are available:
| `npm run server:dev` | Run development server |
| **Test** | |
| `npm run test:lint` | Run all linters |
| `npm run test:lint:eslint` | Run linter eslint |
| `npm run test:lint:remark` | Run linter remark |
| `npm run test:unit` | Run all unit tests in watch mode |
| `npm run test:unit:coverage` | Run all unit tests and generate coverage report |
| `npm test` | Run all tests & linters |
@ -70,7 +73,6 @@ The following endpoints are provided given the right command is executed or all
| [http://localhost:6006](http://localhost:6006) | Storybook |
| [http://localhost:8080](http://localhost:8080) | Documentation |
## TODO
- [x] vite
@ -124,6 +126,9 @@ Currently none
[badge-eslint-img]: https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fraw.githubusercontent.com%2FIT4Change%2Fboilerplate-frontend%2Fmaster%2Fpackage.json&query=devDependencies.eslint&label=eslint&color=yellow
[badge-eslint-href]: https://eslint.org/
[badge-remark-cli-img]: https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fraw.githubusercontent.com%2FIT4Change%2Fboilerplate-frontend%2Fmaster%2Fpackage.json&query=devDependencies%5B%27remark-cli%27%5D&label=remark-cli&color=yellow
[badge-remark-cli-href]: https://remark.js.org/
[badge-vitest-img]: https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fraw.githubusercontent.com%2FIT4Change%2Fboilerplate-frontend%2Fmaster%2Fpackage.json&query=devDependencies.vitest&label=vitest&color=yellow
[badge-vitest-href]: https://vitest.dev/
@ -131,4 +136,4 @@ Currently none
[badge-storybook-href]: https://storybook.js.org/
[badge-vuepress-img]: https://img.shields.io/badge/dynamic/json?url=https%3A%2F%2Fraw.githubusercontent.com%2FIT4Change%2Fboilerplate-frontend%2Fmaster%2Fpackage.json&query=devDependencies.vuepress&label=vuepress&color=orange
[badge-vuepress-href]: https://vuepress.vuejs.org/
[badge-vuepress-href]: https://vuepress.vuejs.org/

9547
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -21,7 +21,8 @@
"vitest",
"vue-i18n",
"vuepress",
"docker"
"docker",
"remark-cli"
],
"author": "Ulf Gebhardt",
"license": "Apache-2.0",
@ -38,7 +39,9 @@
"server:prod": "cross-env NODE_ENV=production npm run server",
"storybook": "storybook dev -p 6006",
"storybook:build": "storybook build -o build/storybook",
"test:lint": "eslint --ext .vue,.ts,.tsx,.js,.jsx,.json,.yml,.yaml --max-warnings 0 --ignore-path .gitignore .",
"test:lint": "npm run test:lint:eslint && npm run test:lint:remark",
"test:lint:eslint": "eslint --ext .vue,.ts,.tsx,.js,.jsx,.json,.yml,.yaml --max-warnings 0 --ignore-path .gitignore .",
"test:lint:remark": "remark . --quiet --frail",
"test:unit": "vitest",
"test:unit:coverage": "npm run test:unit -- run --coverage",
"test": "npm run test:lint && npm run test:unit:coverage",
@ -101,6 +104,11 @@
"prettier": "^3.1.0",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"remark-cli": "^12.0.0",
"remark-gfm": "^4.0.0",
"remark-preset-lint-consistent": "^5.1.2",
"remark-preset-lint-markdown-style-guide": "^5.1.3",
"remark-preset-lint-recommended": "^6.1.3",
"storybook": "^7.5.3",
"vitest": "^0.34.6",
"vuepress": "^2.0.0-rc.0"