Package Exports
- remark-inline-links
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (remark-inline-links) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
remark-inline-links

remark plugin to transform references and definitions into normal links and images.
Installation
npm:
npm install remark-inline-links
Usage
Say we have the following file, example.md
:
[foo], [foo][], [bar][foo].
![foo], ![foo][], ![bar][foo].
[foo]: http://example.com "Example Domain"
And our script, example.js
, looks as follows:
var fs = require('fs')
var remark = require('remark')
var links = require('remark-inline-links')
remark()
.use(links)
.process(fs.readFileSync('example.md'), function(err, file) {
if (err) throw err
console.log(String(file))
})
Now, running node example
yields:
[foo](http://example.com "Example Domain"), [foo](http://example.com "Example Domain"), [bar](http://example.com "Example Domain").
, , .
API
remark().use(inlineLinks[, options])
Transform references and definitions into normal links and images.
Options
options.commonmark
boolean
, default: false
— Turn on to use CommonMark handling of duplicate
definitions: use the first definition, ignore duplicate definitions.
The default behaviour is to prefer the last found duplicate definition.
Related
remark-bookmarks
— Link managerremark-reference-links
— Reverse ofremark-inline-links
, thus rewriting normal links and images into references and definitionsremark-defsplit
— Practically the same asremark-reference-links
, but with URI-based identifiers instead of numerical onesremark-unlink
— Remove all links, references and definitions
Contribute
See contributing.md
in remarkjs/remark
for ways to get
started.
This organisation has a Code of Conduct. By interacting with this repository, organisation, or community you agree to abide by its terms.