* Add internal support for deprecated packages in tooling
* Remove `remark-lint-no-auto-link-without-protocol` from presets
* Add info to `remark-lint-no-auto-link-without-protocol` on why it’s deprecated
Related to remarkjs/remark#863.
This change updates the `repository` field in all `package.json`s to add a `directory`.
This also modifies the scripts to get the repository URLs.
Closes GH-268.
Closes GH-269.
Reviewed-by: Titus Wormer <tituswormer@gmail.com>
* Update to a micromark parser
* The markdown parser is now CommonMark compliant
* Several rules work on GFM features (literal autolinks, tables,
strikethrough, tasklist).
Make sure to install `remark-gfm` if you’re using GFM
* A couple of positions in messages moved a tad bit to make more sense
Most plugins are fine, but some received majors.
The following plugins are made for the new parser and do not work on
the old.
While you’re still on remark 12, use their previous version.
Use the new versions for remark 13+.
* `remark-lint-checkbox-character-style`
* `remark-lint-checkbox-content-indent`
* `remark-lint-list-item-bullet-indent`
* `remark-lint-list-item-spacing`
* `remark-lint-no-blockquote-without-marker`
* `remark-lint-no-heading-indent`
* `remark-lint-no-paragraph-content-indent`
* `remark-lint-no-table-indentation`
* `remark-lint-table-cell-padding`
* `remark-lint-table-pipes`
These plugins generally work on old and new remark, but might miss some
messages in the old one now:
* `remark-lint-no-consecutive-blank-lines` (extra blank lines can no
longer break out of lists)
* `remark-lint-no-heading-content-indent` (pedantic mode no longer
supported)
* `remark-lint-no-inline-padding` (emphasis, strong, strikethrough
can’t be padded anymore)
* `remark-lint-no-undefined-references` (undefined references are no
longer parsed, so we have to do magic to find them)
This commit rewrites most of the documentation per rule and preset,
`remark-lint` itself, and `unified-lint-rule`.
* Better and more readable automatic examples
* Check and update all rule descriptions
* Use middot (·) and line-feed (␊) for relevant examples
* Unify descriptions of `'consistent`'
* Add some more docs where needed
Closes GH-158.
Closes GH-97.
Previously, severities could be passed in as numbers,
for example: `[1, 80]`. This commit introduces support
for passing in these severities as strings. Thus adding
the right most column:
| Type | Off | Warning | Error |
| ------- | ------- | ---------------- | --------- |
| boolean | `false` | `true` | |
| number | `0` | `1` | `2` |
| string | `'off'` | `'on'`, `'warn'` | `'error'` |
> Note that strings cannot (currently) be passed in
> directly: they must be wrapped in an array: `'error'`
> does not work, `['error']` does.
Closes GH-81.
This adds proper support for presets in **remark-lint**.
This is a big one: **remark-lint** no longer does anything
without you telling it to.
* Update internals, docs, examples, to turn `reset`
on by default;
* Refactor project to monorepo;
* Move library to `./packages/remark-lint`;
* Add the following preset packages:
* `remark-preset-lint-consistent`;
* `remark-preset-lint-recommended`;
* `remark-preset-lint-legacy`.
If you’re using the CLI, please add one or more of these presets
to your configuration file.
On the API, note that presets are node modules, so it’s possible
to `require` them as well.
Previously, messages could be either turned on (as warnings), or
turned off. This update adds support for setting these through an
integer (`1` and `0` respectivly), in array form:
```js
remark().use(lint, {finalNewline:[0]});
```
Additionally, the integer `2` can be passed to turn a message into
a fatal error:
```js
remark().use(lint, {maximumLineLength: [2, 72]});
```
Closes GH-65.
* Remove requirement for synchronous rules to accept, and
invoke, a `done` handler;
* Add support for returning promises, generators, from
rules.
* Add `doc/external.md`, with a description on how to use
and create external rule packages;
* Add structural fixtures per-rule inline, which are now
shown in (improved) `doc/rules.md`, and used in testing
each rule;
* Add contributors to `package.json`;
* Remove history before stable from changelog;
* Refactor tests to use `tape` instead of `mocha`;
* Add automated generation of `rules.js` index;
* Fix incorrect badges.
Although there was a system in place to warn users about invalid
lint options, it failed to report those messages.
* Additionally, fix several typographic errors in documentation.
Closes GH-33.