-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
remark-lint #27
Milestone
Comments
arcticicestudio
added a commit
that referenced
this issue
Aug 24, 2019
Installed `remark-lint` (1) that is part of `remark-cli` (2). `remark-preset-lint-arcticicestudio` (3) is used as rule preset that implements the Arctic ice Studio Markdown Style Guide (4). References: (1) https://github.com/remarkjs/remark-lint (2) https://github.com/remarkjs/remark/tree/master/packages/remark-cli (3) https://github.com/arcticicestudio/remark-preset-lint-arcticicestudio (4) https://github.com/arcticicestudio.github.io/styleguide-markdown GH-27
arcticicestudio
added a commit
that referenced
this issue
Aug 24, 2019
Created the main "remark" (1) configuration file and initially sets up the `remark-preset-lint-arcticicestudio` (2) preset. Also added the `.remarkignore` file with defined ignore pattern. References: (1) https://remark.js.org (2) https://github.com/remarkjs/remark-lint (3) https://github.com/arcticicestudio/remark-preset-lint-arcticicestudio GH-27
arcticicestudio
added a commit
that referenced
this issue
Aug 24, 2019
The package script/task allows to run the Markdown linting separately and is included in the main linting script flow. References: (1) https://github.com/mysticatea/npm-run-all GH-27
Merged
arcticicestudio
added a commit
that referenced
this issue
Aug 24, 2019
Integrated `remark-lint` (1), that is built on remark (2), the powerful Markdown processor powered by plugins like "remark-lint". "Ensuring the Markdown you (and contributors) write is of great quality will provide better rendering in all the different markdown parsers, and makes sure less refactoring is needed afterwards." "remark-lint" can be used via remark-cli (3) and a rule preset. This preset is `remark-preset-lint-arcticicestudio` (4), the custom preset that implements the "Arctic ice Studio Markdown Style Guide" (5). Since the custom preset is still in major version `0` note that the version range is `>=0.x.x <1.0.0` to avoid the "SemVer Major Zero Caveat". When defining package versions with the the carat `^` or tilde `~` range selector it won't affect packages with a major version of `0`. "yarn" will resolve these packages to their exact version until the major version is greater or equal to `1`. To avoid this caveat the more detailed version range `>=0.x.x <1.0.0` is used to resolve all versions greater or equal to `0.x.x` but less than `1.0.0`. This will always use the latest `0.x.x` version and removes the need to increment the version manually on each new release. >>> Configuration The `.remarkrc.js` configuration file is placed in the project root as well as the `.remarkignore` file to also define ignore pattern. >>> Package script/task To allow to run the Markdown linting separately a `lint:md` package script/task has been added to be including the main `lint` script flow. References: (1) https://github.com/remarkjs/remark-lint (2) https://remark.js.org (3) https://www.npmjs.com/package/remark-cli (4) https://github.com/arcticicestudio/remark-preset-lint-arcticicestudio (5) https://arcticicestudio.github.io/styleguide-markdown Resolves GH-27
arcticicestudio
added a commit
that referenced
this issue
Aug 24, 2019
Integrated `lint-staged` (1) to run linters against staged Git files to prevent to add code that violates any style guide into the code base. >>> Configuration The configuration file `lint-staged.config.js` is placed in the project root and includes the command that should be run for matching file extensions (globs). It includes at least the three following entries with the same order as listed here: 1. `prettier --list-different` - Run Prettier (GH-32) against `*.{js,json,md,mdx,ts,tsx,yml}` to ensure all files are formatted correctly. The `--list-different` prints the found files that are not conform to the Prettier configuration. 2. `eslint` - Run ESLint (GH-30) against `*.{js,ts,tsx}` to ensure all TypeScript and JavaScript files are compliant to the style guide after being formatted with Prettier. 3. `remark --no-stdout` - Run remark-lint (GH-27) against `*.md` to ensure all Markdown files are compliant to the style guide. The `--no-stdout` flag suppresses the output of the parsed file content. References: (1) https://github.com/okonet/lint-staged (2) https://www.npmjs.com/package/lint-staged Resolves GH-33
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Integrate remark-lint which is built on remark, the powerful Markdown processor powered by plugins such as remark-lint.
remark-lint can be used via remark-cli and a rule preset. This preset will be remark-preset-lint-arcticicestudio, the custom preset that implements the Arctic ice Studio Markdown Style Guide.
Since the custom preset is still in major version
0
note that the version range should be>=0.x.x <1.0.0
to avoid the “SemVer Major Zero Caveat”. When defining package versions with the the carat^
or tilde~
range selector it won't affect packages with a major version of0
. yarn will resolve these packages to their exact version until the major version is greater or equal to1
.To avoid this caveat the more detailed version range
>=0.x.x <1.0.0
should be used to resolve all versions greater or equal to0.x.x
but less than1.0.0
. This will always use the latest0.x.x
version and removes the need to increment the version manually on each new release.Configuration
The
.remarkrc.js
configuration file will be placed in the project root as well as the.remarkignore
file to also define ignore pattern.Package script/task
To allow to run the Markdown linting separately a
lint:md
package script/task will be added to be included in the mainlint
script flow.Tasks
.remarkrc.js
configuration file..remarkignore
ignore pattern file.lint:md
script/task.The text was updated successfully, but these errors were encountered: