Skip to content

Commit 6df612d

Browse files
committed
Update mdast to remark
1 parent 846e993 commit 6df612d

File tree

8 files changed

+35
-35
lines changed

8 files changed

+35
-35
lines changed

.editorconfig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ charset = utf-8
88
trim_trailing_whitespace = true
99
insert_final_newline = true
1010

11-
[*.{json,svg,mdastrc,eslintrc}]
11+
[*.{json,svg,remarkrc,eslintrc}]
1212
indent_size = 2
1313

1414
[*.md]
File renamed without changes.

.mdastrc renamed to .remarkrc

File renamed without changes.

example.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
var heading = require('./index.js');
2-
var mdast = require('mdast');
2+
var remark = require('remark');
33

44
// Callback invoked when a heading is found.
55
function onrun(start, nodes, end) {
@@ -19,7 +19,7 @@ function onrun(start, nodes, end) {
1919
}
2020

2121
// Process a document.
22-
var doc = mdast().use(heading('foo', onrun)).process(
22+
var doc = remark().use(heading('foo', onrun)).process(
2323
'# Foo\n' +
2424
'\n' +
2525
'Bar.\n' +

history.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,45 @@
1-
<!--mdast setext-->
1+
<!--remark setext-->
22

33
<!--lint disable no-multiple-toplevel-headings-->
44

55
1.0.2 / 2015-08-23
66
==================
77

8-
* Fix bug where nodes were passed incorrectly ([4b036e4](https://github.com/wooorm/mdast-util-heading-range/commit/4b036e4))
8+
* Fix bug where nodes were passed incorrectly ([`4b036e4`](https://github.com/wooorm/mdast-util-heading-range/commit/4b036e4))
99

1010
1.0.1 / 2015-08-19
1111
==================
1212

13-
* Fix bug ([689f250](https://github.com/wooorm/mdast-util-heading-range/commit/689f250))
13+
* Fix bug ([`689f250`](https://github.com/wooorm/mdast-util-heading-range/commit/689f250))
1414

1515
1.0.0 / 2015-08-18
1616
==================
1717

18-
* Refactor to make installation section smaller ([b5699e5](https://github.com/wooorm/mdast-util-heading-range/commit/b5699e5))
19-
* Update dependencies, dev-dependencies ([25f00b9](https://github.com/wooorm/mdast-util-heading-range/commit/25f00b9))
18+
* Refactor to make installation section smaller ([`b5699e5`](https://github.com/wooorm/mdast-util-heading-range/commit/b5699e5))
19+
* Update dependencies, dev-dependencies ([`25f00b9`](https://github.com/wooorm/mdast-util-heading-range/commit/25f00b9))
2020

2121
0.1.3 / 2015-07-12
2222
==================
2323

24-
* Remove peer-dependencies ([47589b6](https://github.com/wooorm/mdast-util-heading-range/commit/47589b6))
24+
* Remove peer-dependencies ([`47589b6`](https://github.com/wooorm/mdast-util-heading-range/commit/47589b6))
2525

2626
0.1.2 / 2015-06-14
2727
==================
2828

29-
* Remove `.npmignore` in favour of `files` in `package.json` ([abfc010](https://github.com/wooorm/mdast-util-heading-range/commit/abfc010))
30-
* Add mdast-lint as a dev-dependency ([8520a6c](https://github.com/wooorm/mdast-util-heading-range/commit/8520a6c))
31-
* Refactor lint targets ([f1bf4b9](https://github.com/wooorm/mdast-util-heading-range/commit/f1bf4b9))
32-
* Add `.editorconfig` ([6765f89](https://github.com/wooorm/mdast-util-heading-range/commit/6765f89))
33-
* Update mdast ([e0b6e90](https://github.com/wooorm/mdast-util-heading-range/commit/e0b6e90))
34-
* Update browserify, eslint, jscs-jsdoc ([be1259e](https://github.com/wooorm/mdast-util-heading-range/commit/be1259e))
29+
* Remove `.npmignore` in favour of `files` in `package.json` ([`abfc010`](https://github.com/wooorm/mdast-util-heading-range/commit/abfc010))
30+
* Add mdast-lint as a dev-dependency ([`8520a6c`](https://github.com/wooorm/mdast-util-heading-range/commit/8520a6c))
31+
* Refactor lint targets ([`f1bf4b9`](https://github.com/wooorm/mdast-util-heading-range/commit/f1bf4b9))
32+
* Add `.editorconfig` ([`6765f89`](https://github.com/wooorm/mdast-util-heading-range/commit/6765f89))
33+
* Update mdast ([`e0b6e90`](https://github.com/wooorm/mdast-util-heading-range/commit/e0b6e90))
34+
* Update browserify, eslint, jscs-jsdoc ([`be1259e`](https://github.com/wooorm/mdast-util-heading-range/commit/be1259e))
3535

3636
0.1.1 / 2015-04-15
3737
==================
3838

39-
* Update eslint ([63ae427](https://github.com/wooorm/mdast-util-heading-range/commit/63ae427))
40-
* Update mdast ([09dc2a3](https://github.com/wooorm/mdast-util-heading-range/commit/09dc2a3))
41-
* Add mdast-toc as a dependency ([49d1bf3](https://github.com/wooorm/mdast-util-heading-range/commit/49d1bf3))
42-
* Rebuild ([7a7ae6e](https://github.com/wooorm/mdast-util-heading-range/commit/7a7ae6e))
39+
* Update eslint ([`63ae427`](https://github.com/wooorm/mdast-util-heading-range/commit/63ae427))
40+
* Update mdast ([`09dc2a3`](https://github.com/wooorm/mdast-util-heading-range/commit/09dc2a3))
41+
* Add mdast-toc as a dependency ([`49d1bf3`](https://github.com/wooorm/mdast-util-heading-range/commit/49d1bf3))
42+
* Rebuild ([`7a7ae6e`](https://github.com/wooorm/mdast-util-heading-range/commit/7a7ae6e))
4343

4444
0.1.0 / 2015-04-15
4545
==================

package.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,13 @@
2424
"istanbul": "^0.3.0",
2525
"jscs": "^2.0.0",
2626
"jscs-jsdoc": "^1.0.0",
27-
"mdast": "^1.0.0",
28-
"mdast-comment-config": "^1.0.0",
29-
"mdast-github": "^0.3.0",
30-
"mdast-lint": "^1.0.0",
31-
"mdast-toc": "^0.5.0",
32-
"mdast-usage": "^0.3.0",
33-
"mdast-validate-links": "^0.3.0",
27+
"remark": "^3.0.0",
28+
"remark-comment-config": "^2.0.0",
29+
"remark-github": "^3.0.0",
30+
"remark-lint": "^2.0.0",
31+
"remark-toc": "^2.0.0",
32+
"remark-usage": "^2.0.0",
33+
"remark-validate-links": "^2.0.0",
3434
"mocha": "^2.0.0"
3535
},
3636
"scripts": {
@@ -44,7 +44,7 @@
4444
"make": "npm run lint && npm run test-coverage",
4545
"bundle": "browserify index.js --no-builtins -s mdastUtilHeadingRange > mdast-util-heading-range.js",
4646
"postbundle": "esmangle mdast-util-heading-range.js > mdast-util-heading-range.min.js",
47-
"build-md": "mdast . --output --quiet",
47+
"build-md": "remark . --quiet --frail",
4848
"build": "npm run bundle && npm run build-md"
4949
}
5050
}

readme.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ module, [uncompressed](mdast-util-heading-range.js) and [compressed](mdast-util-
3131

3232
```javascript
3333
var heading = require('mdast-util-heading-range');
34-
var mdast = require('mdast');
34+
var remark = require('remark');
3535
```
3636

3737
Callback invoked when a heading is found.
@@ -57,7 +57,7 @@ function onrun(start, nodes, end) {
5757
Process a document.
5858

5959
```javascript
60-
var doc = mdast().use(heading('foo', onrun)).process(
60+
var doc = remark().use(heading('foo', onrun)).process(
6161
'# Foo\n' +
6262
'\n' +
6363
'Bar.\n' +

test.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*/
88

99
var heading = require('./');
10-
var mdast = require('mdast');
10+
var remark = require('remark');
1111
var assert = require('assert');
1212

1313
/*
@@ -42,7 +42,7 @@ function remover(processor, name) {
4242
* @return {string}
4343
*/
4444
function process(value, options) {
45-
return mdast().use(remover, options).process(value);
45+
return remark().use(remover, options).process(value);
4646
}
4747

4848
/*
@@ -227,7 +227,7 @@ describe('mdast-util-heading-range(heading, callback)', function () {
227227
});
228228

229229
it('should not remove anything when `null` is given', function (done) {
230-
mdast().use(function (processor) {
230+
remark().use(function (processor) {
231231
processor.use(heading('foo', function () {
232232
return null;
233233
}));
@@ -239,7 +239,7 @@ describe('mdast-util-heading-range(heading, callback)', function () {
239239
});
240240

241241
it('should replace all previous nodes otherwise', function (done) {
242-
mdast().use(function (processor) {
242+
remark().use(function (processor) {
243243
processor.use(heading('foo', function () {
244244
return [];
245245
}));
@@ -251,7 +251,7 @@ describe('mdast-util-heading-range(heading, callback)', function () {
251251
});
252252

253253
it('should insert all returned nodes', function (done) {
254-
mdast().use(function (processor) {
254+
remark().use(function (processor) {
255255
processor.use(heading('foo', function (start, nodes, end) {
256256
return [
257257
start,
@@ -270,7 +270,7 @@ describe('mdast-util-heading-range(heading, callback)', function () {
270270

271271
it('should call back with the correct number of children', function (done) {
272272
var seen;
273-
mdast().use(function (processor) {
273+
remark().use(function (processor) {
274274
processor.use(heading('foo', function (start, nodes) {
275275
seen = nodes;
276276
return null;

0 commit comments

Comments
 (0)