remark-validate-links
Advanced tools
Comparing version 8.0.2 to 8.0.3
@@ -33,4 +33,6 @@ 'use strict' | ||
/* eslint-disable node/no-deprecated-api */ | ||
var parse = url.parse | ||
var format = url.format | ||
/* eslint-enable node/no-deprecated-api */ | ||
@@ -37,0 +39,0 @@ var viewPaths = { |
{ | ||
"name": "remark-validate-links", | ||
"version": "8.0.2", | ||
"description": "Validate links to headings and files in markdown", | ||
"version": "8.0.3", | ||
"description": "remark plugin to validate links to headings and files", | ||
"license": "MIT", | ||
"keywords": [ | ||
"unified", | ||
"remark", | ||
"plugin", | ||
"mdast", | ||
"markdown", | ||
"validate", | ||
@@ -11,4 +16,3 @@ "link", | ||
"file", | ||
"heading", | ||
"remark" | ||
"heading" | ||
], | ||
@@ -19,3 +23,9 @@ "repository": "remarkjs/remark-validate-links", | ||
"contributors": [ | ||
"Titus Wormer <tituswormer@gmail.com> (https://wooorm.com)" | ||
"Titus Wormer <tituswormer@gmail.com> (https://wooorm.com)", | ||
"Diogo Nunes <dialex.nunes@gmail.com>", | ||
"Jonathan Haines <jonno.haines@gmail.com>", | ||
"Merlijn Vos <merlijn@soverin.net>", | ||
"Andrew Petro <andrew.w.petro@gmail.com>", | ||
"wangshijun <wangshijun2010@gmail.com>", | ||
"Anton Rybochkin <anton.rybochkin@axibase.com>" | ||
], | ||
@@ -37,11 +47,12 @@ "files": [ | ||
"execa": "^1.0.0", | ||
"nyc": "^13.0.0", | ||
"nyc": "^14.0.0", | ||
"prettier": "^1.0.0", | ||
"remark": "^10.0.0", | ||
"remark-cli": "^6.0.0", | ||
"remark-preset-wooorm": "^4.0.0", | ||
"remark-preset-wooorm": "^5.0.0", | ||
"strip-ansi": "^5.0.0", | ||
"tape": "^4.0.0", | ||
"to-vfile": "^5.0.0", | ||
"vfile-sort": "^2.1.3", | ||
"xo": "^0.23.0" | ||
"to-vfile": "^6.0.0", | ||
"vfile-sort": "^2.0.0", | ||
"xo": "^0.24.0" | ||
}, | ||
@@ -48,0 +59,0 @@ "scripts": { |
@@ -6,8 +6,9 @@ # remark-validate-links | ||
[![Downloads][downloads-badge]][downloads] | ||
[![Chat][chat-badge]][chat] | ||
[![Size][size-badge]][size] | ||
[![Sponsors][sponsors-badge]][collective] | ||
[![Backers][backers-badge]][collective] | ||
[![Chat][chat-badge]][chat] | ||
[**remark**][remark] plugin to validate that Markdown links and images | ||
reference existing local files and headings. | ||
[**remark**][remark] plugin to validate that Markdown links and images reference | ||
existing local files and headings. | ||
It does not check external URLs (see [`remark-lint-no-dead-urls`][no-dead-urls] | ||
@@ -17,17 +18,17 @@ for that). | ||
For example, this document does not have a heading named `Hello`. | ||
So if we link to that (`[welcome](#hello)`), this plugin will warn | ||
about it. | ||
So if we link to that (`[welcome](#hello)`), this plugin will warn about it. | ||
In addition, when I link to a heading in another document | ||
(`examples/foo.md#hello`), if this file exists but the heading does not, | ||
or if the file does not exist, this plugin will also warn. | ||
(`examples/foo.md#hello`), if this file exists but the heading does not, or if | ||
the file does not exist, this plugin will also warn. | ||
Linking to other files, such as `license` or `index.js` (when they exist) | ||
is fine. | ||
Linking to other files, such as `license` or `index.js` (when they exist) is | ||
fine. | ||
## Table of Contents | ||
* [Installation](#installation) | ||
* [Command line](#command-line) | ||
* [Programmatic](#programmatic) | ||
* [Install](#install) | ||
* [Use](#use) | ||
* [CLI](#cli) | ||
* [API](#api) | ||
* [Configuration](#configuration) | ||
@@ -39,12 +40,14 @@ * [Integration](#integration) | ||
## Installation | ||
## Install | ||
[npm][]: | ||
```bash | ||
```sh | ||
npm install remark-validate-links | ||
``` | ||
## Command line | ||
## Use | ||
### CLI | ||
Use `remark-validate-links` together with [**remark**][remark]: | ||
@@ -82,5 +85,6 @@ | ||
## Programmatic | ||
### API | ||
> Note: The API only checks links to headings. Other URLs are not checked. | ||
> Note: The API only checks links to headings. | ||
> Other URLs are not checked. | ||
@@ -104,3 +108,3 @@ Say we have the following file, `example.md`: | ||
```javascript | ||
```js | ||
var vfile = require('to-vfile') | ||
@@ -130,7 +134,7 @@ var report = require('vfile-reporter') | ||
You can pass a `repository`, containing anything `package.json`s | ||
[`repository`][package-repository] can handle. If this is omitted, | ||
`remark-validate-links` will try the `package.json` in your current working | ||
directory. | ||
[`repository`][package-repository] can handle. | ||
If this is not given, `remark-validate-links` will try the `package.json` in | ||
the current working directory. | ||
```bash | ||
```sh | ||
remark --use 'validate-links=repository:"foo/bar"' example.md | ||
@@ -140,3 +144,3 @@ ``` | ||
When a repository is given or detected (supporting GitHub, GitLab, and | ||
Bitbucket), links to the files are normalized to the file-system. | ||
Bitbucket), links to the files are normalized to the file system. | ||
For example, `https://github.com/foo/bar/blob/master/example.md` becomes | ||
@@ -180,7 +184,9 @@ `example.md`. | ||
See [`contributing.md` in `remarkjs/remark`][contributing] for ways to get | ||
started. | ||
See [`contributing.md`][contributing] in [`remarkjs/.github`][health] for ways | ||
to get started. | ||
See [`support.md`][support] for ways to get help. | ||
This organisation has a [Code of Conduct][coc]. By interacting with this | ||
repository, organisation, or community you agree to abide by its terms. | ||
This project has a [Code of Conduct][coc]. | ||
By interacting with this repository, organisation, or community you agree to | ||
abide by its terms. | ||
@@ -193,3 +199,3 @@ ## License | ||
[build-badge]: https://img.shields.io/travis/remarkjs/remark-validate-links.svg | ||
[build-badge]: https://img.shields.io/travis/remarkjs/remark-validate-links/master.svg | ||
@@ -206,5 +212,5 @@ [build]: https://travis-ci.org/remarkjs/remark-validate-links | ||
[chat-badge]: https://img.shields.io/badge/join%20the%20community-on%20spectrum-7b16ff.svg | ||
[size-badge]: https://img.shields.io/bundlephobia/minzip/remark-validate-links.svg | ||
[chat]: https://spectrum.chat/unified/remark | ||
[size]: https://bundlephobia.com/result?p=remark-validate-links | ||
@@ -217,22 +223,30 @@ [sponsors-badge]: https://opencollective.com/unified/sponsors/badge.svg | ||
[license]: license | ||
[chat-badge]: https://img.shields.io/badge/join%20the%20community-on%20spectrum-7b16ff.svg | ||
[author]: https://wooorm.com | ||
[chat]: https://spectrum.chat/unified/remark | ||
[npm]: https://docs.npmjs.com/cli/install | ||
[remark]: https://github.com/remarkjs/remark | ||
[health]: https://github.com/remarkjs/.github | ||
[remark-lint]: https://github.com/remarkjs/remark-lint | ||
[contributing]: https://github.com/remarkjs/.github/blob/master/contributing.md | ||
[no-dead-urls]: https://github.com/davidtheclark/remark-lint-no-dead-urls | ||
[support]: https://github.com/remarkjs/.github/blob/master/support.md | ||
[remark-html]: https://github.com/remarkjs/remark-html | ||
[coc]: https://github.com/remarkjs/.github/blob/master/code-of-conduct.md | ||
[package-repository]: https://docs.npmjs.com/files/package.json#repository | ||
[license]: license | ||
[author]: https://wooorm.com | ||
[remark]: https://github.com/remarkjs/remark | ||
[cli]: https://github.com/remarkjs/remark/tree/master/packages/remark-cli#readme | ||
[contributing]: https://github.com/remarkjs/remark/blob/master/contributing.md | ||
[remark-lint]: https://github.com/remarkjs/remark-lint | ||
[coc]: https://github.com/remarkjs/remark/blob/master/code-of-conduct.md | ||
[remark-html]: https://github.com/remarkjs/remark-html | ||
[no-dead-urls]: https://github.com/davidtheclark/remark-lint-no-dead-urls | ||
[package-repository]: https://docs.npmjs.com/files/package.json#repository |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
19391
343
242
11