Skip to content

Commit 2ff6eac

Browse files
committed
Remove superfluous comments
1 parent d71e652 commit 2ff6eac

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+54
-927
lines changed

index.js

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,2 @@
1-
/**
2-
* @author Titus Wormer
3-
* @copyright 2015 Titus Wormer
4-
* @license MIT
5-
* @module mdast:to-hast
6-
* @fileoverview Transform MDAST to HAST.
7-
*/
8-
91
'use strict';
10-
11-
/* eslint-env commonjs */
12-
13-
/* Expose. */
142
module.exports = require('./lib/index.js');

lib/all.js

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,11 @@
1-
/**
2-
* @author Titus Wormer
3-
* @copyright 2015 Titus Wormer
4-
* @license MIT
5-
* @module mdast:to-hast:all
6-
* @fileoverview Visit all MDAST nodes.
7-
*/
8-
91
'use strict';
102

11-
/* eslint-env commonjs */
12-
13-
/* Expose. */
143
module.exports = all;
154

16-
/* Dependencies. */
175
var trim = require('trim');
186
var one = require('./one');
197

20-
/**
21-
* Transform the children of `parent`.
22-
*
23-
* @param {Function} h - Hyperscript DSL.
24-
* @param {Node} parent - Parent to visit.
25-
* @return {Array.<Node>} - HAST nodes.
26-
*/
8+
/* Transform the children of `parent`. */
279
function all(h, parent) {
2810
var nodes = parent.children || [];
2911
var length = nodes.length;

lib/failsafe.js

Lines changed: 2 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,12 @@
1-
/**
2-
* @author Titus Wormer
3-
* @copyright 2015 Titus Wormer
4-
* @license MIT
5-
* @module mdast:to-hast:failsafe
6-
* @fileoverview Failsafe to stringify references
7-
* without definitions back to markdown.
8-
*/
9-
101
'use strict';
112

12-
/* eslint-env commonjs */
13-
14-
/* Expose. */
153
module.exports = failsafe;
164

17-
/* Dependencies. */
185
var u = require('unist-builder');
196
var all = require('./all');
207

21-
/**
22-
* Return the content of a reference without definition
23-
* as markdown.
24-
*
25-
* @param {Function} h - Hyperscript DSL.
26-
* @param {Node} node - Node to compile.
27-
* @param {Node?} [definition] - Definition node.
28-
* @return {Array.<string>?} - Node, list of nodes, or nothing.
29-
*/
8+
/* Return the content of a reference without definition
9+
* as markdown. */
3010
function failsafe(h, node, definition) {
3111
var subtype = node.referenceType;
3212

lib/footer.js

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,12 @@
1-
/**
2-
* @author Titus Wormer
3-
* @copyright 2015 Titus Wormer
4-
* @license MIT
5-
* @module mdast:to-hast:footnotes
6-
* @fileoverview Generate the footnote footer.
7-
*/
8-
91
'use strict';
102

11-
/* eslint-env commonjs */
12-
13-
/* Expose. */
143
module.exports = generateFootnotes;
154

16-
/* Dependencies. */
175
var thematicBreak = require('./handlers/thematic-break');
186
var list = require('./handlers/list');
197
var wrap = require('./wrap');
208

21-
/**
22-
* Transform all footnote definitions, if any.
23-
*
24-
* @param {Function} h - Hyperscript DSL.
25-
* @return {Node?} - Compiled footnotes, if any.
26-
*/
9+
/* Transform all footnote definitions, if any. */
2710
function generateFootnotes(h) {
2811
var footnotes = h.footnotes;
2912
var length = footnotes.length;

lib/handlers/blockquote.js

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,11 @@
1-
/**
2-
* @author Titus Wormer
3-
* @copyright 2015 Titus Wormer
4-
* @license MIT
5-
* @module mdast:to-hast:handlers:blockquote
6-
* @fileoverview Handle a `blockquote`.
7-
*/
8-
91
'use strict';
102

11-
/* eslint-env commonjs */
12-
13-
/* Expose. */
143
module.exports = blockquote;
154

16-
/* Dependencies. */
175
var wrap = require('../wrap');
186
var all = require('../all');
197

20-
/**
21-
* Transform a block quote.
22-
*
23-
* @param {Function} h - Hyperscript DSL.
24-
* @param {Node} node - Node to compile.
25-
* @return {Node} - HAST node.
26-
*/
8+
/* Transform a block quote. */
279
function blockquote(h, node) {
2810
return h(node, 'blockquote', wrap(all(h, node), true));
2911
}

lib/handlers/break.js

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,10 @@
1-
/**
2-
* @author Titus Wormer
3-
* @copyright 2015 Titus Wormer
4-
* @license MIT
5-
* @module mdast:to-hast:handlers:break
6-
* @fileoverview Handle a `break`.
7-
*/
8-
91
'use strict';
102

11-
/* eslint-env commonjs */
12-
13-
/* Expose. */
143
module.exports = hardBreak;
154

16-
/* Dependencies. */
175
var u = require('unist-builder');
186

19-
/**
20-
* Transform an inline break.
21-
*
22-
* @param {Function} h - Hyperscript DSL.
23-
* @param {Node} node - Node to compile.
24-
* @return {Array.<Node>} - HAST nodes.
25-
*/
7+
/* Transform an inline break. */
268
function hardBreak(h, node) {
279
return [h(node, 'br'), u('text', '\n')];
2810
}

lib/handlers/code.js

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,11 @@
1-
/**
2-
* @author Titus Wormer
3-
* @copyright 2015 Titus Wormer
4-
* @license MIT
5-
* @module mdast:to-hast:handlers:code
6-
* @fileoverview Handle `code`.
7-
*/
8-
91
'use strict';
102

11-
/* eslint-env commonjs */
12-
13-
/* Expose. */
143
module.exports = code;
154

16-
/* Dependencies. */
175
var detab = require('detab');
186
var u = require('unist-builder');
197

20-
/**
21-
* Transform a code block.
22-
*
23-
* @param {Function} h - Hyperscript DSL.
24-
* @param {Node} node - Node to compile.
25-
* @return {Node} - HAST node.
26-
*/
8+
/* Transform a code block. */
279
function code(h, node) {
2810
var value = node.value ? detab(node.value + '\n') : '';
2911
var lang = node.lang && node.lang.match(/^[^ \t]+(?=[ \t]|$)/);

lib/handlers/delete.js

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,10 @@
1-
/**
2-
* @author Titus Wormer
3-
* @copyright 2015 Titus Wormer
4-
* @license MIT
5-
* @module mdast:to-hast:handlers:delete
6-
* @fileoverview Handle `delete`.
7-
*/
8-
91
'use strict';
102

11-
/* eslint-env commonjs */
12-
13-
/* Expose. */
143
module.exports = strikethrough;
154

16-
/* Dependencies. */
175
var all = require('../all');
186

19-
/**
20-
* Transform deletions.
21-
*
22-
* @param {Function} h - Hyperscript DSL.
23-
* @param {Node} node - Node to compile.
24-
* @return {Node} - HAST node.
25-
*/
7+
/* Transform deletions. */
268
function strikethrough(h, node) {
279
return h(node, 'del', all(h, node));
2810
}

lib/handlers/emphasis.js

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,10 @@
1-
/**
2-
* @author Titus Wormer
3-
* @copyright 2015 Titus Wormer
4-
* @license MIT
5-
* @module mdast:to-hast:handlers:emphasis
6-
* @fileoverview Handle `emphasis`.
7-
*/
8-
91
'use strict';
102

11-
/* eslint-env commonjs */
12-
13-
/* Expose. */
143
module.exports = emphasis;
154

16-
/* Dependencies. */
175
var all = require('../all');
186

19-
/**
20-
* Transform emphasis
21-
*
22-
* @param {Function} h - Hyperscript DSL.
23-
* @param {Node} node - Node to compile.
24-
* @return {Node} - HAST node.
25-
*/
7+
/* Transform emphasis. */
268
function emphasis(h, node) {
279
return h(node, 'em', all(h, node));
2810
}

lib/handlers/footnote-reference.js

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,10 @@
1-
/**
2-
* @author Titus Wormer
3-
* @copyright 2015 Titus Wormer
4-
* @license MIT
5-
* @module mdast:to-hast:handlers:footnote-reference
6-
* @fileoverview Handle `footnoteReference`.
7-
*/
8-
91
'use strict';
102

11-
/* eslint-env commonjs */
12-
13-
/* Expose. */
143
module.exports = footnoteReference;
154

16-
/* Dependencies. */
175
var u = require('unist-builder');
186

19-
/**
20-
* Transform a reference to a footnote.
21-
*
22-
* @param {Function} h - Hyperscript DSL.
23-
* @param {Node} node - Node to compile.
24-
* @return {Node} - HAST node.
25-
*/
7+
/* Transform a reference to a footnote. */
268
function footnoteReference(h, node) {
279
var identifier = node.identifier;
2810

0 commit comments

Comments
 (0)