Implement documentation linter (#47)

This patch implements documentation linter, which leaves under `test/doclint`
folder.

The documentation linter works like this:
1. Parse javascript source code with esprima and construct a "documentation" out of source code
2. Generate HTML out of `api.md` and traverse the HTML with puppeteer.
3. Make sure javascript aligns nicely with HTML

The documentation linter adds the following commands:
- `yarn doc` - to test that documentation covers all the relevant apis
- `yarn generate-toc` - to update the table-of-contents for the `api.md`
This commit is contained in:
Andrey Lushnikov 2017-07-07 19:36:45 +03:00 committed by GitHub
parent 18b2a46a83
commit 62cacbe5f5
11 changed files with 1715 additions and 61 deletions

View File

@ -2,62 +2,66 @@
##### Table of Contents
+ [class: Browser](#class-browser)
- [new Browser([options])](#new-browseroptions)
- [browser.close()](#browserclose)
- [browser.closePage()](#browserclosepage)
- [browser.newPage()](#browsernewpage)
- [browser.version()](#browserversion)
+ [class: Page](#class-page)
- [page.addScriptTag(url)](#pageaddscripttagurl)
- [page.close()](#pageclose)
- [page.evaluate(fun, args)](#pageevaluatefun-args)
- [page.evaluateOnInitialized(fun, args)](#pageevaluateoninitializedfun-args)
- [page.httpHeaders()](#pagehttpheaders)
- [page.frames()](#pageframes)
- [page.injectFile(filePath)](#pageinjectfilefilepath)
- [page.mainFrame()](#pagemainframe)
- [page.navigate(url)](#pagenavigateurl)
- [page.plainText()](#pageplaintext)
- [page.printToPDF(filePath[, options])](#pageprinttopdffilepath-options)
- [page.screenshot([options])](#pagescreenshotoptions)
- [page.setContent(html)](#pagesetcontenthtml)
- [page.setHTTPHeaders(headers)](#pagesethttpheadersheaders)
- [page.setInPageCallback(name, callback)](#pagesetinpagecallbackname-callback)
- [page.setRequestInterceptor()](#pagesetrequestinterceptor)
- [page.setUserAgent(userAgent)](#pagesetuseragentuseragent)
- [page.setViewportSize(size)](#pagesetviewportsizesize)
- [page.title()](#pagetitle)
- [page.url()](#pageurl)
- [page.userAgent()](#pageuseragent)
- [page.viewportSize()](#pageviewportsize)
+ [class: Dialog](#class-dialog)
- [dialog.accept()](#dialogaccept)
- [dialog.dismiss()](#dialogdismiss)
- [dialog.message()](#dialogmessage)
+ [class: Frame](#class-frame)
- [frame.childFrames()](#framechildframes)
- [frame.evaluate(fun, args)](#frameevaluatefun-args)
- [frame.isDetached()](#frameisdetached)
- [frame.isMainFrame()](#frameismainframe)
- [frame.name()](#framename)
- [frame.parentFrame()](#frameparentframe)
- [frame.securityOrigin()](#framesecurityorigin)
- [frame.url()](#frameurl)
+ [class: Request](#class-request)
- [new Request()](#new-request)
- [request.abort()](#requestabort)
- [request.continue()](#requestcontinue)
- [request.handled()](#requesthandled)
- [request.headers()](#requestheaders)
- [request.method()](#requestmethod)
- [request.method()](#requestmethod-1)
- [request.postData()](#requestpostdata)
- [request.setHeader()](#requestsetheader)
- [request.setMethod()](#requestsetmethod)
- [request.setPostData()](#requestsetpostdata)
- [request.setUrl()](#requestseturl)
- [request.url()](#requesturl)
<!-- toc -->
- [class: Browser](#class-browser)
* [new Browser([options])](#new-browseroptions)
* [browser.close()](#browserclose)
* [browser.closePage()](#browserclosepage)
* [browser.newPage()](#browsernewpage)
* [browser.version()](#browserversion)
- [class: Page](#class-page)
* [page.addScriptTag(url)](#pageaddscripttagurl)
* [page.close()](#pageclose)
* [page.evaluate(fun, args)](#pageevaluatefun-args)
* [page.evaluateOnInitialized(fun, args)](#pageevaluateoninitializedfun-args)
* [page.httpHeaders()](#pagehttpheaders)
* [page.frames()](#pageframes)
* [page.injectFile(filePath)](#pageinjectfilefilepath)
* [page.mainFrame()](#pagemainframe)
* [page.navigate(url)](#pagenavigateurl)
* [page.plainText()](#pageplaintext)
* [page.printToPDF(filePath[, options])](#pageprinttopdffilepath-options)
* [page.screenshot([options])](#pagescreenshotoptions)
* [page.setContent(html)](#pagesetcontenthtml)
* [page.setHTTPHeaders(headers)](#pagesethttpheadersheaders)
* [page.setInPageCallback(name, callback)](#pagesetinpagecallbackname-callback)
* [page.setRequestInterceptor()](#pagesetrequestinterceptor)
* [page.setUserAgent(userAgent)](#pagesetuseragentuseragent)
* [page.setViewportSize(size)](#pagesetviewportsizesize)
* [page.title()](#pagetitle)
* [page.url()](#pageurl)
* [page.userAgent()](#pageuseragent)
* [page.viewportSize()](#pageviewportsize)
- [class: Dialog](#class-dialog)
* [dialog.accept()](#dialogaccept)
* [dialog.dismiss()](#dialogdismiss)
* [dialog.message()](#dialogmessage)
- [class: Frame](#class-frame)
* [frame.childFrames()](#framechildframes)
* [frame.evaluate(fun, args)](#frameevaluatefun-args)
* [frame.isDetached()](#frameisdetached)
* [frame.isMainFrame()](#frameismainframe)
* [frame.name()](#framename)
* [frame.parentFrame()](#frameparentframe)
* [frame.securityOrigin()](#framesecurityorigin)
* [frame.url()](#frameurl)
- [class: Request](#class-request)
* [new Request()](#new-request)
* [request.abort()](#requestabort)
* [request.continue()](#requestcontinue)
* [request.handled()](#requesthandled)
* [request.headers()](#requestheaders)
* [request.method()](#requestmethod)
* [request.method()](#requestmethod-1)
* [request.postData()](#requestpostdata)
* [request.setHeader()](#requestsetheader)
* [request.setMethod()](#requestsetmethod)
* [request.setPostData()](#requestsetpostdata)
* [request.setUrl()](#requestseturl)
* [request.url()](#requesturl)
<!-- tocstop -->
### class: Browser

934
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -11,7 +11,9 @@
"test-phantom": "python third_party/phantomjs/test/run-tests.py",
"test": "npm run lint --silent && npm run unit && npm run test-phantom",
"install": "node install.js",
"lint": "[ \"$CI\" = true ] && eslint --quiet -f codeframe . || eslint ."
"lint": "[ \"$CI\" = true ] && eslint --quiet -f codeframe . || eslint .",
"generate-toc": "markdown-toc -i docs/api.md",
"doc": "jasmine test/doclint/lint.js"
},
"author": "The Chromium Authors",
"license": "SEE LICENSE IN LICENSE",
@ -26,9 +28,12 @@
"chromium_revision": "484159"
},
"devDependencies": {
"commonmark": "^0.27.0",
"deasync": "^0.1.9",
"eslint": "^4.0.0",
"esprima": "^4.0.0",
"jasmine": "^2.6.0",
"markdown-toc": "^1.1.0",
"minimist": "^1.2.0",
"ncp": "^2.0.0",
"pixelmatch": "^4.0.2",

View File

@ -0,0 +1,26 @@
let Documentation = {};
Documentation.Class = class {
/**
* @param {string} name
* @param {!Array<!Documentation.Method>} methodsArray
*/
constructor(name, methodsArray) {
this.name = name;
this.methodsArray = methodsArray;
this.methods = new Map();
for (let method of methodsArray)
this.methods.set(method.name, method);
}
};
Documentation.Method = class {
/**
* @param {string} name
*/
constructor(name) {
this.name = name;
}
};
module.exports = Documentation;

52
test/doclint/JSOutline.js Normal file
View File

@ -0,0 +1,52 @@
const esprima = require('esprima');
const ESTreeWalker = require('../../third_party/chromium/ESTreeWalker');
const Documentation = require('./Documentation');
class JSOutline {
constructor(text) {
this.classes = [];
this._currentClassName = null;
this._currentClassMethods = [];
this._text = text;
let ast = esprima.parseScript(this._text, {loc: true, range: true});
let walker = new ESTreeWalker(node => {
if (node.type === 'ClassDeclaration')
this._onClassDeclaration(node);
else if (node.type === 'MethodDefinition')
this._onMethodDefinition(node);
});
walker.walk(ast);
this._flushClassIfNeeded();
}
_onClassDeclaration(node) {
this._flushClassIfNeeded();
this._currentClassName = this._getIdentifier(node.id);
}
_onMethodDefinition(node) {
console.assert(this._currentClassName !== null);
let methodName = this._getIdentifier(node.key);
let method = new Documentation.Method(methodName);
this._currentClassMethods.push(method);
}
_flushClassIfNeeded() {
if (this._currentClassName === null)
return;
let jsClass = new Documentation.Class(this._currentClassName, this._currentClassMethods);
this.classes.push(jsClass);
this._currentClassName = null;
this._currentClassMethods = [];
}
_getIdentifier(node) {
if (!node)
return null;
let text = this._text.substring(node.range[0], node.range[1]).trim();
return /^[$A-Z_][0-9A-Z_$]*$/i.test(text) ? text : null;
}
}
module.exports = JSOutline;

85
test/doclint/MDOutline.js Normal file
View File

@ -0,0 +1,85 @@
const Documentation = require('./Documentation');
const commonmark = require('commonmark');
const Browser = require('../../lib/Browser');
class MDOutline {
constructor(text) {
this.classes = [];
this.html = MDOutline.compile(text);
}
static compile(text) {
const reader = new commonmark.Parser();
const parsed = reader.parse(text);
const writer = new commonmark.HtmlRenderer();
const html = writer.render(parsed);
return html;
}
async collectHeadings() {
const browser = new Browser({args: ['--no-sandbox']});
const page = await browser.newPage();
await page.setContent(this.html);
this.headings = await page.evaluate(getTOCHeadings);
await browser.close();
}
buildClasses() {
const headings = this.headings;
const classHeading = /^class: (\w+)$/;
const constructorRegex = /^new (\w+)\((.*)\)$/;
const methodRegex = /^(\w+)\.(\w+)\((.*)\)$/;
let currentClassName = null;
let currentClassMethods = [];
for (const heading of Object.keys(headings)) {
let match = heading.match(classHeading);
currentClassName = match[1];
for (const title of headings[heading]) {
let className = null;
let methodName = null;
if (constructorRegex.test(title)) {
let match = title.match(constructorRegex);
className = match[1];
methodName = 'constructor';
} else if (methodRegex.test(title)) {
let match = title.match(methodRegex);
className = match[1];
methodName = match[2];
}
if (!currentClassName || !className || !methodName || className.toLowerCase() !== currentClassName.toLowerCase()) {
console.warn('failed to process header as method: ' + heading);
continue;
}
let method = new Documentation.Method(methodName);
currentClassMethods.push(method);
}
flushClassIfNeeded.call(this);
}
function flushClassIfNeeded() {
if (currentClassName === null)
return;
this.classes.push(new Documentation.Class(currentClassName, currentClassMethods));
currentClassName = null;
currentClassMethods = [];
}
}
}
function getTOCHeadings(){
const headings = {};
document.querySelectorAll('h3').forEach((domainEl, i) => {
const methods = [];
let currElem = domainEl;
while ((currElem = currElem.nextElementSibling) && !currElem.matches('h3')) {
if (currElem.matches('h4'))
methods.push(currElem.textContent);
}
headings[domainEl.textContent] = methods;
});
return headings;
}
module.exports = MDOutline;

145
test/doclint/lint.js Normal file
View File

@ -0,0 +1,145 @@
const fs = require('fs');
const path = require('path');
const JSOutline = require('./JSOutline');
const MDOutline = require('./MDOutline');
const Documentation = require('./Documentation');
const markdownToc = require('markdown-toc');
const PROJECT_DIR = path.join(__dirname, '..', '..');
const apiMdText = fs.readFileSync(path.join(PROJECT_DIR, 'docs', 'api.md'), 'utf8');
let EXCLUDE_CLASSES = new Set([
'Helper',
'FrameManager',
'Navigator',
'Connection'
]);
let EXCLUDE_METHODS = new Set([
'frame.constructor',
'dialog.constructor',
'page.create',
'page.constructor'
]);
// Build up documentation from JS sources.
let jsClassesArray = [];
let files = fs.readdirSync(path.join(PROJECT_DIR, 'lib'));
for (let file of files) {
if (!file.endsWith('.js'))
continue;
let filePath = path.join(PROJECT_DIR, 'lib', file);
let outline = new JSOutline(fs.readFileSync(filePath, 'utf8'));
// Filter out private classes and methods.
for (let cls of outline.classes) {
if (EXCLUDE_CLASSES.has(cls.name))
continue;
let methodsArray = cls.methodsArray.filter(method => {
if (method.name.startsWith('_'))
return false;
let shorthand = `${cls.name}.${method.name}`.toLowerCase();
return !EXCLUDE_METHODS.has(shorthand);
});
jsClassesArray.push(new Documentation.Class(cls.name, methodsArray));
}
}
let mdClassesArray;
beforeAll(SX(async function() {
// Build up documentation from MD sources.
let mdOutline = new MDOutline(apiMdText);
await mdOutline.collectHeadings();
mdOutline.buildClasses();
mdClassesArray = mdOutline.classes;
}));
describe('table of contents', function() {
it('should match markdown-toc\'s output', () => {
const newApiMdText = markdownToc.insert(apiMdText);
expect(apiMdText === newApiMdText).toBe(true, 'markdown TOC is outdated, run `yarn generate-toc`');
});
});
// Compare to codebase.
describe('api.md', function() {
let mdClasses = new Map();
let jsClasses = new Map();
it('MarkDown should not contain any duplicate classes', () => {
for (let mdClass of mdClassesArray) {
if (mdClasses.has(mdClass.name))
fail(`Documentation has duplicate declaration of ${mdClass.name}`);
mdClasses.set(mdClass.name, mdClass);
}
});
it('JavaScript should not contain any duplicate classes (probably error in parsing!)', () => {
for (let jsClass of jsClassesArray) {
if (jsClasses.has(jsClass.name))
fail(`JavaScript has duplicate declaration of ${jsClass.name}. (This probably means that this linter has an error)`);
jsClasses.set(jsClass.name, jsClass);
}
});
it('class constructors should be defined before other methods', () => {
for (let mdClass of mdClasses.values()) {
let constructorMethod = mdClass.methods.get('constructor');
if (!constructorMethod)
continue;
if (mdClass.methodsArray[0] !== constructorMethod)
fail(`Method 'new ${mdClass.name}' should go before other methods of class ${mdClass.name}`);
}
});
it('methods should be sorted alphabetically', () => {
for (let mdClass of mdClasses.values()) {
for (let i = 0; i < mdClass.methodsArray.length - 1; ++i) {
// Constructor should always go first.
if (mdClass.methodsArray[i].name === 'constructor')
continue;
let method1 = mdClass.methodsArray[i];
let method2 = mdClass.methodsArray[i + 1];
if (method1.name > method2.name)
fail(`${mdClass.name}.${method1.name} breaks alphabetic sorting inside class ${mdClass.name}`);
}
}
});
it('should not contain any non-existing class', () => {
for (let mdClass of mdClasses.values()) {
if (!jsClasses.has(mdClass.name))
fail(`Documentation describes non-existing class ${mdClass.name}`);
}
});
it('should describe all existing classes', () => {
for (let jsClass of jsClasses.values()) {
if (!mdClasses.has(jsClass.name))
fail(`Documentation lacks description of class ${jsClass.name}`);
}
});
it('should not contain any non-existing methods', () => {
for (let mdClass of mdClasses.values()) {
let jsClass = jsClasses.get(mdClass.name);
if (!jsClass)
continue;
for (let method of mdClass.methods.values()) {
if (!jsClass.methods.has(method.name))
fail(`Documentation describes non-existing method: ${jsClass.name}.${method.name}()`);
}
}
});
it('should describe all existing methods', () => {
for (let jsClass of jsClasses.values()) {
let mdClass = mdClasses.get(jsClass.name);
if (!mdClass)
continue;
for (let method of jsClass.methods.values()) {
if (!mdClass.methods.has(method.name))
fail(`Documentation lacks ${jsClass.name}.${method.name}()`);
}
}
});
});
// Since Jasmine doesn't like async functions, they should be wrapped
// in a SX function.
function SX(fun) {
return done => Promise.resolve(fun()).then(done).catch(done.fail);
}

14
third_party/chromium/CHANGES.md vendored Normal file
View File

@ -0,0 +1,14 @@
Short Name: Chromium
URL: https://chromium.org
Version: 484360
License: The Chromium License
License File: LICENSE
Security Critical: no
Description:
This package is used to get the ESTreeWalker file from Chrome DevTools frontend:
- ESTreeWalker.js
Local Modifications:
- The "formatterWorker" namespace was removed

135
third_party/chromium/ESTreeWalker.js vendored Normal file
View File

@ -0,0 +1,135 @@
// Copyright (c) 2014 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
/**
* @unrestricted
*/
class ESTreeWalker {
/**
* @param {function(!ESTree.Node):(!Object|undefined)} beforeVisit
* @param {function(!ESTree.Node)=} afterVisit
*/
constructor(beforeVisit, afterVisit) {
this._beforeVisit = beforeVisit;
this._afterVisit = afterVisit || new Function();
}
/**
* @param {!ESTree.Node} ast
*/
walk(ast) {
this._innerWalk(ast, null);
}
/**
* @param {!ESTree.Node} node
* @param {?ESTree.Node} parent
*/
_innerWalk(node, parent) {
if (!node)
return;
node.parent = parent;
if (this._beforeVisit.call(null, node) === ESTreeWalker.SkipSubtree) {
this._afterVisit.call(null, node);
return;
}
let walkOrder = ESTreeWalker._walkOrder[node.type];
if (!walkOrder)
return;
if (node.type === 'TemplateLiteral') {
let templateLiteral = /** @type {!ESTree.TemplateLiteralNode} */ (node);
let expressionsLength = templateLiteral.expressions.length;
for (let i = 0; i < expressionsLength; ++i) {
this._innerWalk(templateLiteral.quasis[i], templateLiteral);
this._innerWalk(templateLiteral.expressions[i], templateLiteral);
}
this._innerWalk(templateLiteral.quasis[expressionsLength], templateLiteral);
} else {
for (let i = 0; i < walkOrder.length; ++i) {
let entity = node[walkOrder[i]];
if (Array.isArray(entity))
this._walkArray(entity, node);
else
this._innerWalk(entity, node);
}
}
this._afterVisit.call(null, node);
}
/**
* @param {!Array.<!ESTree.Node>} nodeArray
* @param {?ESTree.Node} parentNode
*/
_walkArray(nodeArray, parentNode) {
for (let i = 0; i < nodeArray.length; ++i)
this._innerWalk(nodeArray[i], parentNode);
}
}
/** @typedef {!Object} ESTreeWalker.SkipSubtree */
ESTreeWalker.SkipSubtree = {};
/** @enum {!Array.<string>} */
ESTreeWalker._walkOrder = {
'AwaitExpression': ['arguments'],
'ArrayExpression': ['elements'],
'ArrowFunctionExpression': ['params', 'body'],
'AssignmentExpression': ['left', 'right'],
'BinaryExpression': ['left', 'right'],
'BlockStatement': ['body'],
'BreakStatement': ['label'],
'CallExpression': ['callee', 'arguments'],
'CatchClause': ['param', 'body'],
'ClassBody': ['body'],
'ClassDeclaration': ['id', 'superClass', 'body'],
'ClassExpression': ['id', 'superClass', 'body'],
'ConditionalExpression': ['test', 'consequent', 'alternate'],
'ContinueStatement': ['label'],
'DebuggerStatement': [],
'DoWhileStatement': ['body', 'test'],
'EmptyStatement': [],
'ExpressionStatement': ['expression'],
'ForInStatement': ['left', 'right', 'body'],
'ForOfStatement': ['left', 'right', 'body'],
'ForStatement': ['init', 'test', 'update', 'body'],
'FunctionDeclaration': ['id', 'params', 'body'],
'FunctionExpression': ['id', 'params', 'body'],
'Identifier': [],
'IfStatement': ['test', 'consequent', 'alternate'],
'LabeledStatement': ['label', 'body'],
'Literal': [],
'LogicalExpression': ['left', 'right'],
'MemberExpression': ['object', 'property'],
'MethodDefinition': ['key', 'value'],
'NewExpression': ['callee', 'arguments'],
'ObjectExpression': ['properties'],
'ObjectPattern': ['properties'],
'ParenthesizedExpression': ['expression'],
'Program': ['body'],
'Property': ['key', 'value'],
'ReturnStatement': ['argument'],
'SequenceExpression': ['expressions'],
'Super': [],
'SwitchCase': ['test', 'consequent'],
'SwitchStatement': ['discriminant', 'cases'],
'TaggedTemplateExpression': ['tag', 'quasi'],
'TemplateElement': [],
'TemplateLiteral': ['quasis', 'expressions'],
'ThisExpression': [],
'ThrowStatement': ['argument'],
'TryStatement': ['block', 'handler', 'finalizer'],
'UnaryExpression': ['argument'],
'UpdateExpression': ['argument'],
'VariableDeclaration': ['declarations'],
'VariableDeclarator': ['id', 'init'],
'WhileStatement': ['test', 'body'],
'WithStatement': ['object', 'body'],
'YieldExpression': ['argument']
};
module.exports = ESTreeWalker;

27
third_party/chromium/LICENSE vendored Normal file
View File

@ -0,0 +1,27 @@
// Copyright 2015 The Chromium Authors. All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
//
// * Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above
// copyright notice, this list of conditions and the following disclaimer
// in the documentation and/or other materials provided with the
// distribution.
// * Neither the name of Google Inc. nor the names of its
// contributors may be used to endorse or promote products derived from
// this software without specific prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

235
yarn.lock
View File

@ -31,6 +31,12 @@ ansi-escapes@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-2.0.0.tgz#5bae52be424878dd9783e8910e3fc2922e83c81b"
ansi-red@^0.1.1:
version "0.1.1"
resolved "https://registry.yarnpkg.com/ansi-red/-/ansi-red-0.1.1.tgz#8c638f9d1080800a353c9c28c8a81ca4705d946c"
dependencies:
ansi-wrap "0.1.0"
ansi-regex@^2.0.0:
version "2.1.1"
resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df"
@ -39,12 +45,23 @@ ansi-styles@^2.2.1:
version "2.2.1"
resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe"
ansi-wrap@0.1.0:
version "0.1.0"
resolved "https://registry.yarnpkg.com/ansi-wrap/-/ansi-wrap-0.1.0.tgz#a82250ddb0015e9a27ca82e82ea603bbfa45efaf"
argparse@^1.0.7:
version "1.0.9"
resolved "https://registry.yarnpkg.com/argparse/-/argparse-1.0.9.tgz#73d83bc263f86e97f8cc4f6bae1b0e90a7d22c86"
dependencies:
sprintf-js "~1.0.2"
argparse@~0.1.15:
version "0.1.16"
resolved "https://registry.yarnpkg.com/argparse/-/argparse-0.1.16.tgz#cfd01e0fbba3d6caed049fbd758d40f65196f57c"
dependencies:
underscore "~1.7.0"
underscore.string "~2.4.0"
array-union@^1.0.1:
version "1.0.2"
resolved "https://registry.yarnpkg.com/array-union/-/array-union-1.0.2.tgz#9a34410e4f4e3da23dea375be5be70f24778ec39"
@ -59,6 +76,10 @@ arrify@^1.0.0:
version "1.0.1"
resolved "https://registry.yarnpkg.com/arrify/-/arrify-1.0.1.tgz#898508da2226f380df904728456849c1501a4b0d"
autolinker@~0.15.0:
version "0.15.3"
resolved "https://registry.yarnpkg.com/autolinker/-/autolinker-0.15.3.tgz#342417d8f2f3461b14cf09088d5edf8791dc9832"
babel-code-frame@^6.22.0:
version "6.22.0"
resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.22.0.tgz#027620bee567a88c32561574e7fd0801d33118e4"
@ -120,11 +141,24 @@ co@^4.6.0:
version "4.6.0"
resolved "https://registry.yarnpkg.com/co/-/co-4.6.0.tgz#6ea6bdf3d853ae54ccb8e47bfa0bf3f9031fb184"
coffee-script@^1.12.4:
version "1.12.6"
resolved "https://registry.yarnpkg.com/coffee-script/-/coffee-script-1.12.6.tgz#285a3f7115689065064d6bf9ef4572db66695cbf"
commonmark@^0.27.0:
version "0.27.0"
resolved "https://registry.yarnpkg.com/commonmark/-/commonmark-0.27.0.tgz#d86c262b962821e9483c69c547bc58840c047b34"
dependencies:
entities "~ 1.1.1"
mdurl "~ 1.0.1"
minimist "~ 1.2.0"
string.prototype.repeat "^0.2.0"
concat-map@0.0.1:
version "0.0.1"
resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b"
concat-stream@1.6.0, concat-stream@^1.6.0:
concat-stream@1.6.0, concat-stream@^1.5.2, concat-stream@^1.6.0:
version "1.6.0"
resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.0.tgz#0aac662fd52be78964d5532f694784e70110acf7"
dependencies:
@ -171,6 +205,10 @@ del@^2.0.2:
pinkie-promise "^2.0.0"
rimraf "^2.2.8"
diacritics-map@^0.1.0:
version "0.1.0"
resolved "https://registry.yarnpkg.com/diacritics-map/-/diacritics-map-0.1.0.tgz#6dfc0ff9d01000a2edf2865371cac316e94977af"
doctrine@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.0.0.tgz#c73d8d2909d22291e1a007a395804da8b665fe63"
@ -178,6 +216,10 @@ doctrine@^2.0.0:
esutils "^2.0.2"
isarray "^1.0.0"
"entities@~ 1.1.1":
version "1.1.1"
resolved "https://registry.yarnpkg.com/entities/-/entities-1.1.1.tgz#6e5c2d0a5621b5dadaecef80b90edfb5cd7772f0"
escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5:
version "1.0.5"
resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4"
@ -237,6 +279,10 @@ esprima@^3.1.1:
version "3.1.3"
resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.1.3.tgz#fdca51cee6133895e3c88d535ce49dbff62a4633"
esprima@^4.0.0:
version "4.0.0"
resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.0.tgz#4499eddcd1110e0b218bacf2fa7f7f59f55ca804"
esquery@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.0.tgz#cfba8b57d7fba93f17298a8a006a04cda13d80fa"
@ -262,6 +308,18 @@ exit@^0.1.2:
version "0.1.2"
resolved "https://registry.yarnpkg.com/exit/-/exit-0.1.2.tgz#0632638f8d877cc82107d30a0fff1a17cba1cd0c"
expand-range@^1.8.1:
version "1.8.2"
resolved "https://registry.yarnpkg.com/expand-range/-/expand-range-1.8.2.tgz#a299effd335fe2721ebae8e257ec79644fc85337"
dependencies:
fill-range "^2.1.0"
extend-shallow@^2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-2.0.1.tgz#51af7d614ad9a9f610ea1bafbb989d6b1c56890f"
dependencies:
is-extendable "^0.1.0"
external-editor@^2.0.4:
version "2.0.4"
resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-2.0.4.tgz#1ed9199da9cbfe2ef2f7a31b2fde8b0d12368972"
@ -302,6 +360,16 @@ file-entry-cache@^2.0.0:
flat-cache "^1.2.1"
object-assign "^4.0.1"
fill-range@^2.1.0:
version "2.2.3"
resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-2.2.3.tgz#50b77dfd7e469bc7492470963699fe7a8485a723"
dependencies:
is-number "^2.1.0"
isobject "^2.0.0"
randomatic "^1.1.3"
repeat-element "^1.1.2"
repeat-string "^1.5.2"
flat-cache@^1.2.1:
version "1.2.2"
resolved "https://registry.yarnpkg.com/flat-cache/-/flat-cache-1.2.2.tgz#fa86714e72c21db88601761ecf2f555d1abc6b96"
@ -311,6 +379,10 @@ flat-cache@^1.2.1:
graceful-fs "^4.1.2"
write "^0.2.1"
for-in@^1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/for-in/-/for-in-1.0.2.tgz#81068d295a8142ec0ac726c6e2200c30fb6d5e80"
fs.realpath@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/fs.realpath/-/fs.realpath-1.0.0.tgz#1504ad2523158caa40db4a2787cb01411994ea4f"
@ -355,6 +427,16 @@ graceful-fs@^4.1.2:
version "4.1.11"
resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.11.tgz#0e8bdfe4d1ddb8854d64e04ea7c00e2a026e5658"
gray-matter@^2.1.0:
version "2.1.1"
resolved "https://registry.yarnpkg.com/gray-matter/-/gray-matter-2.1.1.tgz#3042d9adec2a1ded6a7707a9ed2380f8a17a430e"
dependencies:
ansi-red "^0.1.1"
coffee-script "^1.12.4"
extend-shallow "^2.0.1"
js-yaml "^3.8.1"
toml "^2.3.2"
has-ansi@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz#34f5049ce1ecdf2b0649af3ef24e45ed35416d91"
@ -403,6 +485,14 @@ inquirer@^3.0.6:
strip-ansi "^3.0.0"
through "^2.3.6"
is-buffer@^1.1.5:
version "1.1.5"
resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.5.tgz#1f3b26ef613b214b88cbca23cc6c01d87961eecc"
is-extendable@^0.1.0, is-extendable@^0.1.1:
version "0.1.1"
resolved "https://registry.yarnpkg.com/is-extendable/-/is-extendable-0.1.1.tgz#62b110e289a471418e3ec36a617d472e301dfc89"
is-fullwidth-code-point@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f"
@ -416,6 +506,18 @@ is-my-json-valid@^2.16.0:
jsonpointer "^4.0.0"
xtend "^4.0.0"
is-number@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/is-number/-/is-number-2.1.0.tgz#01fcbbb393463a548f2f466cce16dece49db908f"
dependencies:
kind-of "^3.0.2"
is-number@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/is-number/-/is-number-3.0.0.tgz#24fd6201a4782cf50561c810276afc7d12d71195"
dependencies:
kind-of "^3.0.2"
is-path-cwd@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/is-path-cwd/-/is-path-cwd-1.0.0.tgz#d225ec23132e89edd38fda767472e62e65f1106d"
@ -446,10 +548,16 @@ is-resolvable@^1.0.0:
dependencies:
tryit "^1.0.1"
isarray@^1.0.0, isarray@~1.0.0:
isarray@1.0.0, isarray@^1.0.0, isarray@~1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11"
isobject@^2.0.0, isobject@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/isobject/-/isobject-2.1.0.tgz#f065561096a3f1da2ef46272f815c840d87e0c89"
dependencies:
isarray "1.0.0"
jasmine-core@~2.6.0:
version "2.6.4"
resolved "https://registry.yarnpkg.com/jasmine-core/-/jasmine-core-2.6.4.tgz#dec926cd0a9fa287fb6db5c755fa487e74cecac5"
@ -466,7 +574,7 @@ js-tokens@^3.0.0:
version "3.0.1"
resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.1.tgz#08e9f132484a2c45a30907e9dc4d5567b7f114d7"
js-yaml@^3.8.4:
js-yaml@^3.8.1, js-yaml@^3.8.4:
version "3.8.4"
resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.8.4.tgz#520b4564f86573ba96662af85a8cafa7b4b5a6f6"
dependencies:
@ -491,6 +599,24 @@ jsonpointer@^4.0.0:
version "4.0.1"
resolved "https://registry.yarnpkg.com/jsonpointer/-/jsonpointer-4.0.1.tgz#4fd92cb34e0e9db3c89c8622ecf51f9b978c6cb9"
kind-of@^3.0.2:
version "3.2.2"
resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-3.2.2.tgz#31ea21a734bab9bbb0f32466d893aea51e4a3c64"
dependencies:
is-buffer "^1.1.5"
kind-of@^4.0.0:
version "4.0.0"
resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-4.0.0.tgz#20813df3d712928b207378691a45066fae72dd57"
dependencies:
is-buffer "^1.1.5"
lazy-cache@^2.0.2:
version "2.0.2"
resolved "https://registry.yarnpkg.com/lazy-cache/-/lazy-cache-2.0.2.tgz#b9190a4f913354694840859f8a8f7084d8822264"
dependencies:
set-getter "^0.1.0"
levn@^0.3.0, levn@~0.3.0:
version "0.3.0"
resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee"
@ -498,10 +624,44 @@ levn@^0.3.0, levn@~0.3.0:
prelude-ls "~1.1.2"
type-check "~0.3.2"
list-item@^1.1.1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/list-item/-/list-item-1.1.1.tgz#0c65d00e287cb663ccb3cb3849a77e89ec268a56"
dependencies:
expand-range "^1.8.1"
extend-shallow "^2.0.1"
is-number "^2.1.0"
repeat-string "^1.5.2"
lodash@^4.0.0, lodash@^4.17.4, lodash@^4.3.0:
version "4.17.4"
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.4.tgz#78203a4d1c328ae1d86dca6460e369b57f4055ae"
markdown-link@^0.1.1:
version "0.1.1"
resolved "https://registry.yarnpkg.com/markdown-link/-/markdown-link-0.1.1.tgz#32c5c65199a6457316322d1e4229d13407c8c7cf"
markdown-toc@^1.1.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/markdown-toc/-/markdown-toc-1.1.0.tgz#18e47237d89549e9447121e69e2ca853ca2d752a"
dependencies:
concat-stream "^1.5.2"
diacritics-map "^0.1.0"
gray-matter "^2.1.0"
lazy-cache "^2.0.2"
list-item "^1.1.1"
markdown-link "^0.1.1"
minimist "^1.2.0"
mixin-deep "^1.1.3"
object.pick "^1.2.0"
remarkable "^1.7.1"
repeat-string "^1.6.1"
strip-color "^0.1.0"
"mdurl@~ 1.0.1":
version "1.0.1"
resolved "https://registry.yarnpkg.com/mdurl/-/mdurl-1.0.1.tgz#fe85b2ec75a59037f2adfec100fd6c601761152e"
mime@^1.3.4:
version "1.3.6"
resolved "https://registry.yarnpkg.com/mime/-/mime-1.3.6.tgz#591d84d3653a6b0b4a3b9df8de5aa8108e72e5e0"
@ -520,10 +680,17 @@ minimist@0.0.8:
version "0.0.8"
resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d"
minimist@^1.2.0:
minimist@^1.2.0, "minimist@~ 1.2.0":
version "1.2.0"
resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284"
mixin-deep@^1.1.3:
version "1.2.0"
resolved "https://registry.yarnpkg.com/mixin-deep/-/mixin-deep-1.2.0.tgz#d02b8c6f8b6d4b8f5982d3fd009c4919851c3fe2"
dependencies:
for-in "^1.0.2"
is-extendable "^0.1.1"
mkdirp@0.5.0:
version "0.5.0"
resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.0.tgz#1d73076a6df986cd9344e15e71fcc05a4c9abf12"
@ -564,6 +731,12 @@ object-assign@^4.0.1:
version "4.1.1"
resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863"
object.pick@^1.2.0:
version "1.2.0"
resolved "https://registry.yarnpkg.com/object.pick/-/object.pick-1.2.0.tgz#b5392bee9782da6d9fb7d6afaf539779f1234c2b"
dependencies:
isobject "^2.1.0"
once@^1.3.0:
version "1.4.0"
resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1"
@ -643,6 +816,13 @@ progress@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.0.tgz#8a1be366bf8fc23db2bd23f10c6fe920b4389d1f"
randomatic@^1.1.3:
version "1.1.7"
resolved "https://registry.yarnpkg.com/randomatic/-/randomatic-1.1.7.tgz#c7abe9cc8b87c0baa876b19fde83fd464797e38c"
dependencies:
is-number "^3.0.0"
kind-of "^4.0.0"
readable-stream@^2.2.2:
version "2.3.0"
resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.0.tgz#640f5dcda88c91a8dc60787145629170813a1ed2"
@ -655,6 +835,21 @@ readable-stream@^2.2.2:
string_decoder "~1.0.0"
util-deprecate "~1.0.1"
remarkable@^1.7.1:
version "1.7.1"
resolved "https://registry.yarnpkg.com/remarkable/-/remarkable-1.7.1.tgz#aaca4972100b66a642a63a1021ca4bac1be3bff6"
dependencies:
argparse "~0.1.15"
autolinker "~0.15.0"
repeat-element@^1.1.2:
version "1.1.2"
resolved "https://registry.yarnpkg.com/repeat-element/-/repeat-element-1.1.2.tgz#ef089a178d1483baae4d93eb98b4f9e4e11d990a"
repeat-string@^1.5.2, repeat-string@^1.6.1:
version "1.6.1"
resolved "https://registry.yarnpkg.com/repeat-string/-/repeat-string-1.6.1.tgz#8dcae470e1c88abc2d600fff4a776286da75e637"
require-uncached@^1.0.3:
version "1.0.3"
resolved "https://registry.yarnpkg.com/require-uncached/-/require-uncached-1.0.3.tgz#4e0d56d6c9662fd31e43011c4b95aa49955421d3"
@ -703,6 +898,12 @@ safe-buffer@~5.1.0:
version "5.1.0"
resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.0.tgz#fe4c8460397f9eaaaa58e73be46273408a45e223"
set-getter@^0.1.0:
version "0.1.0"
resolved "https://registry.yarnpkg.com/set-getter/-/set-getter-0.1.0.tgz#d769c182c9d5a51f409145f2fba82e5e86e80376"
dependencies:
to-object-path "^0.3.0"
signal-exit@^3.0.2:
version "3.0.2"
resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d"
@ -722,6 +923,10 @@ string-width@^2.0.0:
is-fullwidth-code-point "^2.0.0"
strip-ansi "^3.0.0"
string.prototype.repeat@^0.2.0:
version "0.2.0"
resolved "https://registry.yarnpkg.com/string.prototype.repeat/-/string.prototype.repeat-0.2.0.tgz#aba36de08dcee6a5a337d49b2ea1da1b28fc0ecf"
string_decoder@~1.0.0:
version "1.0.2"
resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.0.2.tgz#b29e1f4e1125fa97a10382b8a533737b7491e179"
@ -734,6 +939,10 @@ strip-ansi@^3.0.0:
dependencies:
ansi-regex "^2.0.0"
strip-color@^0.1.0:
version "0.1.0"
resolved "https://registry.yarnpkg.com/strip-color/-/strip-color-0.1.0.tgz#106f65d3d3e6a2d9401cac0eb0ce8b8a702b4f7b"
strip-json-comments@~2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a"
@ -771,6 +980,16 @@ tmp@^0.0.31:
dependencies:
os-tmpdir "~1.0.1"
to-object-path@^0.3.0:
version "0.3.0"
resolved "https://registry.yarnpkg.com/to-object-path/-/to-object-path-0.3.0.tgz#297588b7b0e7e0ac08e04e672f85c1f4999e17af"
dependencies:
kind-of "^3.0.2"
toml@^2.3.2:
version "2.3.2"
resolved "https://registry.yarnpkg.com/toml/-/toml-2.3.2.tgz#5eded5ca42887924949fd06eb0e955656001e834"
tryit@^1.0.1:
version "1.0.3"
resolved "https://registry.yarnpkg.com/tryit/-/tryit-1.0.3.tgz#393be730a9446fd1ead6da59a014308f36c289cb"
@ -789,6 +1008,14 @@ ultron@~1.1.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/ultron/-/ultron-1.1.0.tgz#b07a2e6a541a815fc6a34ccd4533baec307ca864"
underscore.string@~2.4.0:
version "2.4.0"
resolved "https://registry.yarnpkg.com/underscore.string/-/underscore.string-2.4.0.tgz#8cdd8fbac4e2d2ea1e7e2e8097c42f442280f85b"
underscore@~1.7.0:
version "1.7.0"
resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.7.0.tgz#6bbaf0877500d36be34ecaa584e0db9fef035209"
util-deprecate@~1.0.1:
version "1.0.2"
resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf"