remark-usage
Advanced tools
Comparing version 2.0.0 to 2.0.1
@@ -1,5 +0,11 @@ | ||
<!--mdast setext--> | ||
<!--remark setext--> | ||
<!--lint disable no-multiple-toplevel-headings--> | ||
2.0.1 / 2015-12-25 | ||
================== | ||
* Refactor to replace mocha with tape ([a8d7a48](https://github.com/wooorm/remark-usage/commit/a8d7a48)) | ||
* Replace internal dependency of mdast > remark ([27cb95a](https://github.com/wooorm/remark-usage/commit/27cb95a)) | ||
2.0.0 / 2015-12-24 | ||
@@ -6,0 +12,0 @@ ================== |
21
index.js
@@ -11,2 +11,4 @@ /** | ||
/* eslint-env node */ | ||
/* | ||
@@ -18,3 +20,3 @@ * Dependencies. | ||
var path = require('path'); | ||
var mdast = require('mdast'); | ||
var remark = require('remark'); | ||
var uncached = require('require-uncached'); | ||
@@ -61,3 +63,3 @@ var heading = require('mdast-util-heading-range'); | ||
* @param {string} value - Content to process. | ||
* @return {string} | ||
* @return {string} - Preprocessed `value`. | ||
*/ | ||
@@ -81,3 +83,4 @@ function preprocess(value) { | ||
* @param {string} source - Scripts source. | ||
* @return {Array.<Object>} | ||
* @param {Object} options - Configuration. | ||
* @return {Array.<Object>} - List of tokens. | ||
*/ | ||
@@ -137,3 +140,3 @@ function script(source, options) { | ||
* @param {Object} info - Code node. | ||
* @return {Node} | ||
* @return {Node} - mdast node. | ||
*/ | ||
@@ -153,6 +156,6 @@ function log(info) { | ||
* @param {string} value - Value to parse. | ||
* @return {Array.<Node>} | ||
* @return {Array.<Node>} - List of mdast nodes. | ||
*/ | ||
function parse(value) { | ||
return mdast.parse(value, { | ||
return remark.parse(value, { | ||
'position': false | ||
@@ -167,3 +170,4 @@ }).children; | ||
* @param {Object} logs - List of logs. | ||
* @return {Array.<Node>} | ||
* @param {Object} options - Configuration. | ||
* @return {Array.<Node>} - List of mdast nodes. | ||
*/ | ||
@@ -253,3 +257,3 @@ function postprocess(value, logs, options) { | ||
* @param {Object} options - Configuration. | ||
* @return {function(node)} | ||
* @return {function(node)} - Bound heading-range callback. | ||
*/ | ||
@@ -263,2 +267,3 @@ function runFactory(options) { | ||
* @param {Array.<Node>} nodes - Content. | ||
* @param {Node} end - Ending heading. | ||
*/ | ||
@@ -265,0 +270,0 @@ return function (start, nodes, end) { |
{ | ||
"name": "remark-usage", | ||
"version": "2.0.0", | ||
"version": "2.0.1", | ||
"description": "Add a usage example to your README", | ||
@@ -19,3 +19,3 @@ "license": "MIT", | ||
"cept": "^1.0.0", | ||
"mdast": "^3.0.0-alpha.5", | ||
"remark": "^3.0.0", | ||
"mdast-util-heading-range": "^1.0.0", | ||
@@ -28,24 +28,22 @@ "require-uncached": "^1.0.2", | ||
"eslint": "^1.0.0", | ||
"istanbul": "^0.3.0", | ||
"istanbul": "^0.4.0", | ||
"jscs": "^2.0.0", | ||
"jscs-jsdoc": "^1.0.0", | ||
"mdast-github": "^2.0.0-alpha.1", | ||
"mdast-lint": "^2.0.0-alpha.1", | ||
"mdast-slug": "^2.0.0", | ||
"mdast-comment-config": "^2.0.0-alpha.1", | ||
"mdast-validate-links": "^1.0.0", | ||
"mocha": "^2.0.0" | ||
"remark-github": "^2.0.0", | ||
"remark-lint": "^2.0.0", | ||
"remark-slug": "^3.0.0", | ||
"remark-comment-config": "^2.0.0", | ||
"remark-validate-links": "^2.0.0", | ||
"tape": "^4.0.0" | ||
}, | ||
"scripts": { | ||
"test-api": "mocha --check-leaks test/index.js", | ||
"test-coverage": "istanbul cover _mocha -- test/index.js", | ||
"test-travis": "npm run test-coverage", | ||
"test": "npm run test-api", | ||
"build-md": "remark . --quiet", | ||
"build": "npm run build-md", | ||
"lint-api": "eslint .", | ||
"lint-style": "jscs --reporter inline .", | ||
"lint": "npm run lint-api && npm run lint-style", | ||
"make": "npm run lint && npm run test-coverage", | ||
"build-md": "mdast . --quiet", | ||
"build": "npm run build-md" | ||
"test-api": "node test/index.js", | ||
"test-coverage": "istanbul cover test/index.js", | ||
"test": "npm run build && npm run lint && npm run test-coverage" | ||
} | ||
} |
@@ -6,6 +6,6 @@ # remark-usage [![Build Status](https://img.shields.io/travis/wooorm/remark-usage.svg)](https://travis-ci.org/wooorm/remark-usage) [![Coverage Status](https://img.shields.io/codecov/c/github/wooorm/remark-usage.svg)](https://codecov.io/github/wooorm/remark-usage) | ||
> :warning: **mdast is currently being renamed to remark** :warning: | ||
> | ||
> | ||
> This means all plug-ins and relating projects change too, causing many | ||
> changes across the ecosystem. Expect the dust to settle in roughly a day. | ||
> | ||
> | ||
> See this project at the previous stable commit | ||
@@ -12,0 +12,0 @@ > [c4a51d1](https://github.com/wooorm/remark-github/commit/c4a51d1). |
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
18704
326
+ Addedremark@^3.0.0
+ Addedansi-escapes@1.4.0(transitive)
+ Addedansi-regex@2.1.1(transitive)
+ Addedansi-styles@2.2.1(transitive)
+ Addedanymatch@1.3.2(transitive)
+ Addedarr-diff@2.0.04.0.0(transitive)
+ Addedarr-flatten@1.1.0(transitive)
+ Addedarr-union@3.1.0(transitive)
+ Addedarray-union@1.0.2(transitive)
+ Addedarray-uniq@1.0.3(transitive)
+ Addedarray-unique@0.2.10.3.2(transitive)
+ Addedarrify@1.0.1(transitive)
+ Addedassign-symbols@1.0.0(transitive)
+ Addedasync-each@1.0.6(transitive)
+ Addedatob@2.1.2(transitive)
+ Addedattach-ware@1.1.1(transitive)
+ Addedbail@1.0.5(transitive)
+ Addedbalanced-match@1.0.2(transitive)
+ Addedbase@0.11.2(transitive)
+ Addedbinary-extensions@1.13.1(transitive)
+ Addedbindings@1.5.0(transitive)
+ Addedbrace-expansion@1.1.11(transitive)
+ Addedbraces@1.8.52.3.2(transitive)
+ Addedbuffer-from@1.1.2(transitive)
+ Addedcache-base@1.0.1(transitive)
+ Addedcamelcase@2.1.1(transitive)
+ Addedccount@1.1.0(transitive)
+ Addedchalk@1.1.3(transitive)
+ Addedcharacter-entities@1.2.4(transitive)
+ Addedcharacter-entities-html4@1.1.4(transitive)
+ Addedcharacter-entities-legacy@1.1.4(transitive)
+ Addedcharacter-reference-invalid@1.1.4(transitive)
+ Addedchokidar@1.7.0(transitive)
+ Addedclass-utils@0.3.6(transitive)
+ Addedcli-cursor@1.0.2(transitive)
+ Addedco@3.1.0(transitive)
+ Addedcode-point-at@1.1.0(transitive)
+ Addedcollapse-white-space@1.0.6(transitive)
+ Addedcollection-visit@1.0.0(transitive)
+ Addedcommander@2.20.3(transitive)
+ Addedcomponent-emitter@1.3.1(transitive)
+ Addedconcat-map@0.0.1(transitive)
+ Addedconcat-stream@1.6.2(transitive)
+ Addedcopy-descriptor@0.1.1(transitive)
+ Addedcore-util-is@1.0.3(transitive)
+ Addeddebug@2.6.9(transitive)
+ Addeddecode-uri-component@0.2.2(transitive)
+ Addeddeep-extend@0.6.0(transitive)
+ Addeddefine-property@0.2.51.0.02.0.2(transitive)
+ Addedelegant-spinner@1.0.1(transitive)
+ Addedescape-string-regexp@1.0.5(transitive)
+ Addedexit-hook@1.1.1(transitive)
+ Addedexpand-brackets@0.1.52.1.4(transitive)
+ Addedexpand-range@1.8.2(transitive)
+ Addedextend@3.0.2(transitive)
+ Addedextend-shallow@2.0.13.0.2(transitive)
+ Addedextend.js@0.0.2(transitive)
+ Addedextglob@0.3.22.0.4(transitive)
+ Addedfile-uri-to-path@1.0.0(transitive)
+ Addedfilename-regex@2.0.1(transitive)
+ Addedfill-range@2.2.44.0.0(transitive)
+ Addedfor-in@1.0.2(transitive)
+ Addedfor-own@0.1.5(transitive)
+ Addedfragment-cache@0.2.1(transitive)
+ Addedfsevents@1.2.13(transitive)
+ Addedfunction-bind@1.1.2(transitive)
+ Addedget-value@2.0.6(transitive)
+ Addedglob@6.0.4(transitive)
+ Addedglob-base@0.3.0(transitive)
+ Addedglob-parent@2.0.0(transitive)
+ Addedglobby@4.1.0(transitive)
+ Addedgraceful-fs@4.2.11(transitive)
+ Addedhas-ansi@2.0.0(transitive)
+ Addedhas-value@0.3.11.0.0(transitive)
+ Addedhas-values@0.1.41.0.0(transitive)
+ Addedhasown@2.0.2(transitive)
+ Addedhe@0.5.0(transitive)
+ Addedinflight@1.0.6(transitive)
+ Addedinherits@2.0.4(transitive)
+ Addedini@1.3.8(transitive)
+ Addedirregular-plurals@1.4.0(transitive)
+ Addedis-accessor-descriptor@1.0.1(transitive)
+ Addedis-alphabetical@1.0.4(transitive)
+ Addedis-alphanumerical@1.0.4(transitive)
+ Addedis-binary-path@1.0.1(transitive)
+ Addedis-buffer@1.1.6(transitive)
+ Addedis-data-descriptor@1.0.1(transitive)
+ Addedis-decimal@1.0.4(transitive)
+ Addedis-descriptor@0.1.71.0.3(transitive)
+ Addedis-dotfile@1.0.3(transitive)
+ Addedis-equal-shallow@0.1.3(transitive)
+ Addedis-extendable@0.1.11.0.1(transitive)
+ Addedis-extglob@1.0.0(transitive)
+ Addedis-fullwidth-code-point@1.0.0(transitive)
+ Addedis-glob@2.0.1(transitive)
+ Addedis-hexadecimal@1.0.4(transitive)
+ Addedis-number@2.1.03.0.04.0.0(transitive)
+ Addedis-plain-object@2.0.4(transitive)
+ Addedis-posix-bracket@0.1.1(transitive)
+ Addedis-primitive@2.0.0(transitive)
+ Addedis-windows@1.0.2(transitive)
+ Addedisarray@1.0.0(transitive)
+ Addedisobject@2.1.03.0.1(transitive)
+ Addedkind-of@3.2.24.0.06.0.3(transitive)
+ Addedlog-symbols@1.0.2(transitive)
+ Addedlog-update@1.0.2(transitive)
+ Addedlongest-streak@1.0.0(transitive)
+ Addedmap-cache@0.2.2(transitive)
+ Addedmap-visit@1.0.0(transitive)
+ Addedmarkdown-table@0.4.0(transitive)
+ Addedmath-random@1.0.4(transitive)
+ Addedmicromatch@2.3.113.1.10(transitive)
+ Addedminimatch@3.1.2(transitive)
+ Addedminimist@1.2.8(transitive)
+ Addedmixin-deep@1.3.2(transitive)
+ Addedms@2.0.0(transitive)
+ Addednan@2.22.0(transitive)
+ Addednanomatch@1.2.13(transitive)
+ Addednormalize-path@2.1.1(transitive)
+ Addednpm-prefix@1.2.0(transitive)
+ Addednumber-is-nan@1.0.1(transitive)
+ Addedobject-assign@4.1.1(transitive)
+ Addedobject-copy@0.1.0(transitive)
+ Addedobject-visit@1.0.1(transitive)
+ Addedobject.omit@2.0.1(transitive)
+ Addedobject.pick@1.3.0(transitive)
+ Addedonce@1.4.0(transitive)
+ Addedonetime@1.1.0(transitive)
+ Addedos-homedir@1.0.2(transitive)
+ Addedparse-entities@1.2.2(transitive)
+ Addedparse-glob@3.0.4(transitive)
+ Addedpascalcase@0.1.1(transitive)
+ Addedpath-is-absolute@1.0.1(transitive)
+ Addedpify@2.3.0(transitive)
+ Addedpinkie@2.0.4(transitive)
+ Addedpinkie-promise@2.0.1(transitive)
+ Addedplur@2.1.2(transitive)
+ Addedposix-character-classes@0.1.1(transitive)
+ Addedpreserve@0.2.0(transitive)
+ Addedprocess-nextick-args@2.0.1(transitive)
+ Addedrandomatic@3.1.1(transitive)
+ Addedrc@1.2.8(transitive)
+ Addedreadable-stream@2.3.8(transitive)
+ Addedreaddirp@2.2.1(transitive)
+ Addedregex-cache@0.4.4(transitive)
+ Addedregex-not@1.0.2(transitive)
+ Addedremark@3.2.3(transitive)
+ Addedremove-trailing-separator@1.1.0(transitive)
+ Addedrepeat-element@1.1.4(transitive)
+ Addedrepeat-string@1.6.1(transitive)
+ Addedresolve-url@0.2.1(transitive)
+ Addedrestore-cursor@1.0.1(transitive)
+ Addedret@0.1.15(transitive)
+ Addedsafe-buffer@5.1.2(transitive)
+ Addedsafe-regex@1.1.0(transitive)
+ Addedset-value@2.0.1(transitive)
+ Addedshellsubstitute@1.2.0(transitive)
+ Addedsnapdragon@0.8.2(transitive)
+ Addedsnapdragon-node@2.1.1(transitive)
+ Addedsnapdragon-util@3.0.1(transitive)
+ Addedsource-map@0.5.7(transitive)
+ Addedsource-map-resolve@0.5.3(transitive)
+ Addedsource-map-url@0.4.1(transitive)
+ Addedsplit-string@3.1.0(transitive)
+ Addedstatic-extend@0.1.2(transitive)
+ Addedstring-width@1.0.2(transitive)
+ Addedstring_decoder@1.1.1(transitive)
+ Addedstringify-entities@1.3.2(transitive)
+ Addedstrip-ansi@3.0.1(transitive)
+ Addedstrip-json-comments@2.0.1(transitive)
+ Addedsupports-color@2.0.0(transitive)
+ Addedtext-table@0.2.0(transitive)
+ Addedto-object-path@0.3.0(transitive)
+ Addedto-regex@3.0.2(transitive)
+ Addedto-regex-range@2.1.1(transitive)
+ Addedto-vfile@1.0.0(transitive)
+ Addedtrim@0.0.1(transitive)
+ Addedtypedarray@0.0.6(transitive)
+ Addedunherit@1.1.3(transitive)
+ Addedunified@2.1.4(transitive)
+ Addedunion-value@1.0.1(transitive)
+ Addedunset-value@1.0.0(transitive)
+ Addeduntildify@2.1.0(transitive)
+ Addedurix@0.1.0(transitive)
+ Addeduse@3.1.1(transitive)
+ Addeduser-home@2.0.0(transitive)
+ Addedutil-deprecate@1.0.2(transitive)
+ Addedvfile@1.4.0(transitive)
+ Addedvfile-find-down@1.0.0(transitive)
+ Addedvfile-find-up@1.0.0(transitive)
+ Addedvfile-reporter@1.5.0(transitive)
+ Addedvfile-sort@1.0.0(transitive)
+ Addedware@1.3.0(transitive)
+ Addedwrap-fn@0.1.5(transitive)
+ Addedwrappy@1.0.2(transitive)
+ Addedxtend@4.0.2(transitive)
- Removedmdast@^3.0.0-alpha.5
- Removedmdast@3.0.0(transitive)