aboutsummaryrefslogtreecommitdiff
path: root/node_modules/section-matter
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/section-matter')
-rw-r--r--node_modules/section-matter/LICENSE21
-rw-r--r--node_modules/section-matter/README.md236
-rw-r--r--node_modules/section-matter/index.js136
-rw-r--r--node_modules/section-matter/node_modules/kind-of/CHANGELOG.md157
-rw-r--r--node_modules/section-matter/node_modules/kind-of/LICENSE21
-rw-r--r--node_modules/section-matter/node_modules/kind-of/README.md365
-rw-r--r--node_modules/section-matter/node_modules/kind-of/index.js129
-rw-r--r--node_modules/section-matter/node_modules/kind-of/package.json88
-rw-r--r--node_modules/section-matter/package.json55
9 files changed, 1208 insertions, 0 deletions
diff --git a/node_modules/section-matter/LICENSE b/node_modules/section-matter/LICENSE
new file mode 100644
index 00000000..5385a098
--- /dev/null
+++ b/node_modules/section-matter/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2017, Jon Schlinkert.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/node_modules/section-matter/README.md b/node_modules/section-matter/README.md
new file mode 100644
index 00000000..95a7a461
--- /dev/null
+++ b/node_modules/section-matter/README.md
@@ -0,0 +1,236 @@
+# section-matter [![NPM version](https://img.shields.io/npm/v/section-matter.svg?style=flat)](https://www.npmjs.com/package/section-matter) [![NPM monthly downloads](https://img.shields.io/npm/dm/section-matter.svg?style=flat)](https://npmjs.org/package/section-matter) [![NPM total downloads](https://img.shields.io/npm/dt/section-matter.svg?style=flat)](https://npmjs.org/package/section-matter) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/section-matter.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/section-matter)
+
+> Like front-matter, but supports multiple sections in a document.
+
+Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support.
+
+## Install
+Install with [npm](https://www.npmjs.com/):
+
+```sh
+$ npm install --save section-matter
+```
+
+## Usage
+
+**Params**
+
+* `input` **{String|Buffer|Object}**: If input is an object, it's `content` property must be a string or buffer.
+* **{Object}**: options
+* `returns` **{Object}**: Returns an object with a `content` string and an array of `sections` objects.
+
+**Example**
+
+```js
+var sections = require('{%= name %}');
+var result = sections(input, options);
+// { content: 'Content before sections', sections: [] }
+```
+
+See available [options](#options).
+
+## Example
+
+_With the exception of front-matter, **which must be the very first thing in the string**, the opening delimiter of all other sections must be followed by a string to be used as the `key` for the section._
+
+Given the following string:
+
+```
+Content before the sections.
+
+---
+
+More content.
+
+---one
+title: One
+---
+
+This is the first section.
+```
+
+The following code:
+
+```js
+console.log(sections(input));
+```
+
+Results in:
+
+```js
+{
+ content: 'Content before the sections.\n\n---\n\nMore content.\n',
+ sections: [
+ {
+ key: 'one',
+ data: 'title: One',
+ content: '\nThis is the first section.'
+ }
+ ]
+}
+```
+
+## Options
+
+### options.section_parse
+
+**Type**: `function`
+
+**Default**: `undefined`
+
+Function to be called on each section after it's parsed from the string.
+
+**Example**
+
+Given the following string (`foo.md`):
+
+```
+This is content before the sections.
+
+---one
+title: First section
+---
+
+This is section one.
+
+---two
+title: Second section
+---
+
+This is section two.
+```
+
+Using the following custom `section_parse` function:
+
+```js
+var fs = require('fs');
+var path = require('path');
+var yaml = require('js-yaml');
+var sections = require('section-matter');
+
+var str = fs.readFileSync('foo.md');
+var options = {
+ section_parse: function(section) {
+ console.log(section)
+ section.key = 'section-' + section.key;
+ section.data = yaml.safeLoad(section.data);
+ }
+};
+
+var result = sections(str, options);
+console.log(result);
+```
+
+Results in:
+
+```js
+{
+ content: 'This is content before the sections.\n',
+ sections: [
+ {
+ key: 'section-one',
+ data: { title: 'First section' },
+ content: '\nThis is section one.\n'
+ },
+ {
+ key: 'section-two',
+ data: { title: 'Second section' },
+ content: '\nThis is section two.\n'
+ }
+ ]
+}
+```
+
+### options.section_delimiter
+
+**Type**: `string`
+
+**Default**: `---`
+
+Delimiter to use as the separator for sections. _With the exception of front-matter, which must be the very first thing in the string, the opening delimiter of all other sections must be followed by a string to be used as the `key` for the section._
+
+**Example**
+
+```js
+var input = '~~~\ntitle: bar\n~~~\n\nfoo\n~~~one\ntitle: One\n~~~\nThis is one';
+console.log(sections(input, {section_delimiter: '~~~'}));
+```
+
+Results in:
+
+```js
+{
+ content: '',
+ sections: [
+ {
+ key: '',
+ data: 'title: bar',
+ content: '\nfoo'
+ },
+ {
+ key: 'one',
+ data: 'title: One',
+ content: 'This is one'
+ }
+ ]
+}
+```
+
+## About
+<details>
+ <summary><strong>Contributing</strong></summary>
+
+Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new).
+
+Please read the [contributing guide](.github/contributing.md) for advice on opening issues, pull requests, and coding standards.
+
+</details>
+
+<details>
+ <summary><strong>Running Tests</strong></summary>
+
+Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command:
+
+```sh
+$ npm install && npm test
+```
+
+</details>
+
+<details>
+ <summary><strong>Building docs</strong></summary>
+
+_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_
+
+To generate the readme, run the following command:
+
+```sh
+$ npm install -g verbose/verb#dev verb-generate-readme && verb
+```
+
+</details>
+
+### Related projects
+
+You might also be interested in these projects:
+
+- [assemble](https://www.npmjs.com/package/assemble): Get the rocks out of your socks! Assemble makes you fast at creating web projects… [more](https://github.com/assemble/assemble) | [homepage](https://github.com/assemble/assemble "Get the rocks out of your socks! Assemble makes you fast at creating web projects. Assemble is used by thousands of projects for rapid prototyping, creating themes, scaffolds, boilerplates, e-books, UI components, API documentation, blogs, building websit")
+- [gray-matter](https://www.npmjs.com/package/gray-matter): Parse front-matter from a string or file. Fast, reliable and easy to use. Parses YAML… [more](https://github.com/jonschlinkert/gray-matter) | [homepage](https://github.com/jonschlinkert/gray-matter "Parse front-matter from a string or file. Fast, reliable and easy to use. Parses YAML front matter by default, but also has support for YAML, JSON, TOML or Coffee Front-Matter, with options to set custom delimiters. Used by metalsmith, assemble, verb and ")
+- [verb](https://www.npmjs.com/package/verb): Documentation generator for GitHub projects. Verb is extremely powerful, easy to use, and is used… [more](https://github.com/verbose/verb) | [homepage](https://github.com/verbose/verb "Documentation generator for GitHub projects. Verb is extremely powerful, easy to use, and is used on hundreds of projects of all sizes to generate everything from API docs to readmes.")
+
+### Contributors
+
+### Author
+**Jon Schlinkert**
+
++ [github/jonschlinkert](https://github.com/jonschlinkert)
++ [twitter/jonschlinkert](https://twitter.com/jonschlinkert)
+
+### License
+Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert).
+Released under the [MIT License](LICENSE).
+
+***
+
+_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on October 23, 2017._
+
diff --git a/node_modules/section-matter/index.js b/node_modules/section-matter/index.js
new file mode 100644
index 00000000..2b4d21e8
--- /dev/null
+++ b/node_modules/section-matter/index.js
@@ -0,0 +1,136 @@
+'use strict';
+
+var typeOf = require('kind-of');
+var extend = require('extend-shallow');
+
+/**
+ * Parse sections in `input` with the given `options`.
+ *
+ * ```js
+ * var sections = require('{%= name %}');
+ * var result = sections(input, options);
+ * // { content: 'Content before sections', sections: [] }
+ * ```
+ * @param {String|Buffer|Object} `input` If input is an object, it's `content` property must be a string or buffer.
+ * @param {Object} options
+ * @return {Object} Returns an object with a `content` string and an array of `sections` objects.
+ * @api public
+ */
+
+module.exports = function(input, options) {
+ if (typeof options === 'function') {
+ options = { parse: options };
+ }
+
+ var file = toObject(input);
+ var defaults = {section_delimiter: '---', parse: identity};
+ var opts = extend({}, defaults, options);
+ var delim = opts.section_delimiter;
+ var lines = file.content.split(/\r?\n/);
+ var sections = null;
+ var section = createSection();
+ var content = [];
+ var stack = [];
+
+ function initSections(val) {
+ file.content = val;
+ sections = [];
+ content = [];
+ }
+
+ function closeSection(val) {
+ if (stack.length) {
+ section.key = getKey(stack[0], delim);
+ section.content = val;
+ opts.parse(section, sections);
+ sections.push(section);
+ section = createSection();
+ content = [];
+ stack = [];
+ }
+ }
+
+ for (var i = 0; i < lines.length; i++) {
+ var line = lines[i];
+ var len = stack.length;
+ var ln = line.trim();
+
+ if (isDelimiter(ln, delim)) {
+ if (ln.length === 3 && i !== 0) {
+ if (len === 0 || len === 2) {
+ content.push(line);
+ continue;
+ }
+ stack.push(ln);
+ section.data = content.join('\n');
+ content = [];
+ continue;
+ }
+
+ if (sections === null) {
+ initSections(content.join('\n'));
+ }
+
+ if (len === 2) {
+ closeSection(content.join('\n'));
+ }
+
+ stack.push(ln);
+ continue;
+ }
+
+ content.push(line);
+ }
+
+ if (sections === null) {
+ initSections(content.join('\n'));
+ } else {
+ closeSection(content.join('\n'));
+ }
+
+ file.sections = sections;
+ return file;
+};
+
+function isDelimiter(line, delim) {
+ if (line.slice(0, delim.length) !== delim) {
+ return false;
+ }
+ if (line.charAt(delim.length + 1) === delim.slice(-1)) {
+ return false;
+ }
+ return true;
+}
+
+function toObject(input) {
+ if (typeOf(input) !== 'object') {
+ input = { content: input };
+ }
+
+ if (typeof input.content !== 'string' && !isBuffer(input.content)) {
+ throw new TypeError('expected a buffer or string');
+ }
+
+ input.content = input.content.toString();
+ input.sections = [];
+ return input;
+}
+
+function getKey(val, delim) {
+ return val ? val.slice(delim.length).trim() : '';
+}
+
+function createSection() {
+ return { key: '', data: '', content: '' };
+}
+
+function identity(val) {
+ return val;
+}
+
+function isBuffer(val) {
+ if (val && val.constructor && typeof val.constructor.isBuffer === 'function') {
+ return val.constructor.isBuffer(val);
+ }
+ return false;
+}
diff --git a/node_modules/section-matter/node_modules/kind-of/CHANGELOG.md b/node_modules/section-matter/node_modules/kind-of/CHANGELOG.md
new file mode 100644
index 00000000..fb30b06d
--- /dev/null
+++ b/node_modules/section-matter/node_modules/kind-of/CHANGELOG.md
@@ -0,0 +1,157 @@
+# Release history
+
+All notable changes to this project will be documented in this file.
+
+The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
+and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
+
+<details>
+ <summary><strong>Guiding Principles</strong></summary>
+
+- Changelogs are for humans, not machines.
+- There should be an entry for every single version.
+- The same types of changes should be grouped.
+- Versions and sections should be linkable.
+- The latest version comes first.
+- The release date of each versions is displayed.
+- Mention whether you follow Semantic Versioning.
+
+</details>
+
+<details>
+ <summary><strong>Types of changes</strong></summary>
+
+Changelog entries are classified using the following labels _(from [keep-a-changelog](http://keepachangelog.com/)_):
+
+- `Added` for new features.
+- `Changed` for changes in existing functionality.
+- `Deprecated` for soon-to-be removed features.
+- `Removed` for now removed features.
+- `Fixed` for any bug fixes.
+- `Security` in case of vulnerabilities.
+
+</details>
+
+## [6.0.0] - 2017-10-13
+
+- refactor code to be more performant
+- refactor benchmarks
+
+## [5.1.0] - 2017-10-13
+
+**Added**
+
+- Merge pull request #15 from aretecode/patch-1
+- adds support and tests for string & array iterators
+
+**Changed**
+
+- updates benchmarks
+
+## [5.0.2] - 2017-08-02
+
+- Merge pull request #14 from struct78/master
+- Added `undefined` check
+
+## [5.0.0] - 2017-06-21
+
+- Merge pull request #12 from aretecode/iterator
+- Set Iterator + Map Iterator
+- streamline `isbuffer`, minor edits
+
+## [4.0.0] - 2017-05-19
+
+- Merge pull request #8 from tunnckoCore/master
+- update deps
+
+## [3.2.2] - 2017-05-16
+
+- fix version
+
+## [3.2.1] - 2017-05-16
+
+- add browserify
+
+## [3.2.0] - 2017-04-25
+
+- Merge pull request #10 from ksheedlo/unrequire-buffer
+- add `promise` support and tests
+- Remove unnecessary `Buffer` check
+
+## [3.1.0] - 2016-12-07
+
+- Merge pull request #7 from laggingreflex/err
+- add support for `error` and tests
+- run update
+
+## [3.0.4] - 2016-07-29
+
+- move tests
+- run update
+
+## [3.0.3] - 2016-05-03
+
+- fix prepublish script
+- remove unused dep
+
+## [3.0.0] - 2015-11-17
+
+- add typed array support
+- Merge pull request #5 from miguelmota/typed-arrays
+- adds new tests
+
+## [2.0.1] - 2015-08-21
+
+- use `is-buffer` module
+
+## [2.0.0] - 2015-05-31
+
+- Create fallback for `Array.isArray` if used as a browser package
+- Merge pull request #2 from dtothefp/patch-1
+- Merge pull request #3 from pdehaan/patch-1
+- Merge branch 'master' of https://github.com/chorks/kind-of into chorks-master
+- optimizations, mostly date and regex
+
+## [1.1.0] - 2015-02-09
+
+- adds `buffer` support
+- adds tests for `buffer`
+
+## [1.0.0] - 2015-01-19
+
+- update benchmarks
+- optimizations based on benchmarks
+
+## [0.1.2] - 2014-10-26
+
+- return `typeof` value if it's not an object. very slight speed improvement
+- use `.slice`
+- adds benchmarks
+
+## [0.1.0] - 2014-9-26
+
+- first commit
+
+[6.0.0]: https://github.com/jonschlinkert/kind-of/compare/5.1.0...6.0.0
+[5.1.0]: https://github.com/jonschlinkert/kind-of/compare/5.0.2...5.1.0
+[5.0.2]: https://github.com/jonschlinkert/kind-of/compare/5.0.1...5.0.2
+[5.0.1]: https://github.com/jonschlinkert/kind-of/compare/5.0.0...5.0.1
+[5.0.0]: https://github.com/jonschlinkert/kind-of/compare/4.0.0...5.0.0
+[4.0.0]: https://github.com/jonschlinkert/kind-of/compare/3.2.2...4.0.0
+[3.2.2]: https://github.com/jonschlinkert/kind-of/compare/3.2.1...3.2.2
+[3.2.1]: https://github.com/jonschlinkert/kind-of/compare/3.2.0...3.2.1
+[3.2.0]: https://github.com/jonschlinkert/kind-of/compare/3.1.0...3.2.0
+[3.1.0]: https://github.com/jonschlinkert/kind-of/compare/3.0.4...3.1.0
+[3.0.4]: https://github.com/jonschlinkert/kind-of/compare/3.0.3...3.0.4
+[3.0.3]: https://github.com/jonschlinkert/kind-of/compare/3.0.0...3.0.3
+[3.0.0]: https://github.com/jonschlinkert/kind-of/compare/2.0.1...3.0.0
+[2.0.1]: https://github.com/jonschlinkert/kind-of/compare/2.0.0...2.0.1
+[2.0.0]: https://github.com/jonschlinkert/kind-of/compare/1.1.0...2.0.0
+[1.1.0]: https://github.com/jonschlinkert/kind-of/compare/1.0.0...1.1.0
+[1.0.0]: https://github.com/jonschlinkert/kind-of/compare/0.1.2...1.0.0
+[0.1.2]: https://github.com/jonschlinkert/kind-of/compare/0.1.0...0.1.2
+[0.1.0]: https://github.com/jonschlinkert/kind-of/commit/2fae09b0b19b1aadb558e9be39f0c3ef6034eb87
+
+[Unreleased]: https://github.com/jonschlinkert/kind-of/compare/0.1.2...HEAD
+[keep-a-changelog]: https://github.com/olivierlacan/keep-a-changelog
+
diff --git a/node_modules/section-matter/node_modules/kind-of/LICENSE b/node_modules/section-matter/node_modules/kind-of/LICENSE
new file mode 100644
index 00000000..3f2eca18
--- /dev/null
+++ b/node_modules/section-matter/node_modules/kind-of/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2014-2017, Jon Schlinkert.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/node_modules/section-matter/node_modules/kind-of/README.md b/node_modules/section-matter/node_modules/kind-of/README.md
new file mode 100644
index 00000000..4b0d4a81
--- /dev/null
+++ b/node_modules/section-matter/node_modules/kind-of/README.md
@@ -0,0 +1,365 @@
+# kind-of [![NPM version](https://img.shields.io/npm/v/kind-of.svg?style=flat)](https://www.npmjs.com/package/kind-of) [![NPM monthly downloads](https://img.shields.io/npm/dm/kind-of.svg?style=flat)](https://npmjs.org/package/kind-of) [![NPM total downloads](https://img.shields.io/npm/dt/kind-of.svg?style=flat)](https://npmjs.org/package/kind-of) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/kind-of.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/kind-of)
+
+> Get the native type of a value.
+
+Please consider following this project's author, [Jon Schlinkert](https://github.com/jonschlinkert), and consider starring the project to show your :heart: and support.
+
+## Install
+
+Install with [npm](https://www.npmjs.com/):
+
+```sh
+$ npm install --save kind-of
+```
+
+Install with [bower](https://bower.io/)
+
+```sh
+$ bower install kind-of --save
+```
+
+## Why use this?
+
+1. [it's fast](#benchmarks) | [optimizations](#optimizations)
+2. [better type checking](#better-type-checking)
+
+## Usage
+
+> es5, es6, and browser ready
+
+```js
+var kindOf = require('kind-of');
+
+kindOf(undefined);
+//=> 'undefined'
+
+kindOf(null);
+//=> 'null'
+
+kindOf(true);
+//=> 'boolean'
+
+kindOf(false);
+//=> 'boolean'
+
+kindOf(new Buffer(''));
+//=> 'buffer'
+
+kindOf(42);
+//=> 'number'
+
+kindOf('str');
+//=> 'string'
+
+kindOf(arguments);
+//=> 'arguments'
+
+kindOf({});
+//=> 'object'
+
+kindOf(Object.create(null));
+//=> 'object'
+
+kindOf(new Test());
+//=> 'object'
+
+kindOf(new Date());
+//=> 'date'
+
+kindOf([1, 2, 3]);
+//=> 'array'
+
+kindOf(/foo/);
+//=> 'regexp'
+
+kindOf(new RegExp('foo'));
+//=> 'regexp'
+
+kindOf(new Error('error'));
+//=> 'error'
+
+kindOf(function () {});
+//=> 'function'
+
+kindOf(function * () {});
+//=> 'generatorfunction'
+
+kindOf(Symbol('str'));
+//=> 'symbol'
+
+kindOf(new Map());
+//=> 'map'
+
+kindOf(new WeakMap());
+//=> 'weakmap'
+
+kindOf(new Set());
+//=> 'set'
+
+kindOf(new WeakSet());
+//=> 'weakset'
+
+kindOf(new Int8Array());
+//=> 'int8array'
+
+kindOf(new Uint8Array());
+//=> 'uint8array'
+
+kindOf(new Uint8ClampedArray());
+//=> 'uint8clampedarray'
+
+kindOf(new Int16Array());
+//=> 'int16array'
+
+kindOf(new Uint16Array());
+//=> 'uint16array'
+
+kindOf(new Int32Array());
+//=> 'int32array'
+
+kindOf(new Uint32Array());
+//=> 'uint32array'
+
+kindOf(new Float32Array());
+//=> 'float32array'
+
+kindOf(new Float64Array());
+//=> 'float64array'
+```
+
+## Benchmarks
+
+Benchmarked against [typeof](http://github.com/CodingFu/typeof) and [type-of](https://github.com/ForbesLindesay/type-of).
+
+```bash
+# arguments (32 bytes)
+ kind-of x 17,024,098 ops/sec ±1.90% (86 runs sampled)
+ lib-type-of x 11,926,235 ops/sec ±1.34% (83 runs sampled)
+ lib-typeof x 9,245,257 ops/sec ±1.22% (87 runs sampled)
+
+ fastest is kind-of (by 161% avg)
+
+# array (22 bytes)
+ kind-of x 17,196,492 ops/sec ±1.07% (88 runs sampled)
+ lib-type-of x 8,838,283 ops/sec ±1.02% (87 runs sampled)
+ lib-typeof x 8,677,848 ops/sec ±0.87% (87 runs sampled)
+
+ fastest is kind-of (by 196% avg)
+
+# boolean (24 bytes)
+ kind-of x 16,841,600 ops/sec ±1.10% (86 runs sampled)
+ lib-type-of x 8,096,787 ops/sec ±0.95% (87 runs sampled)
+ lib-typeof x 8,423,345 ops/sec ±1.15% (86 runs sampled)
+
+ fastest is kind-of (by 204% avg)
+
+# buffer (38 bytes)
+ kind-of x 14,848,060 ops/sec ±1.05% (86 runs sampled)
+ lib-type-of x 3,671,577 ops/sec ±1.49% (87 runs sampled)
+ lib-typeof x 8,360,236 ops/sec ±1.24% (86 runs sampled)
+
+ fastest is kind-of (by 247% avg)
+
+# date (30 bytes)
+ kind-of x 16,067,761 ops/sec ±1.58% (86 runs sampled)
+ lib-type-of x 8,954,436 ops/sec ±1.40% (87 runs sampled)
+ lib-typeof x 8,488,307 ops/sec ±1.51% (84 runs sampled)
+
+ fastest is kind-of (by 184% avg)
+
+# error (36 bytes)
+ kind-of x 9,634,090 ops/sec ±1.12% (89 runs sampled)
+ lib-type-of x 7,735,624 ops/sec ±1.32% (86 runs sampled)
+ lib-typeof x 7,442,160 ops/sec ±1.11% (90 runs sampled)
+
+ fastest is kind-of (by 127% avg)
+
+# function (34 bytes)
+ kind-of x 10,031,494 ops/sec ±1.27% (86 runs sampled)
+ lib-type-of x 9,502,757 ops/sec ±1.17% (89 runs sampled)
+ lib-typeof x 8,278,985 ops/sec ±1.08% (88 runs sampled)
+
+ fastest is kind-of (by 113% avg)
+
+# null (24 bytes)
+ kind-of x 18,159,808 ops/sec ±1.92% (86 runs sampled)
+ lib-type-of x 12,927,635 ops/sec ±1.01% (88 runs sampled)
+ lib-typeof x 7,958,234 ops/sec ±1.21% (89 runs sampled)
+
+ fastest is kind-of (by 174% avg)
+
+# number (22 bytes)
+ kind-of x 17,846,779 ops/sec ±0.91% (85 runs sampled)
+ lib-type-of x 3,316,636 ops/sec ±1.19% (86 runs sampled)
+ lib-typeof x 2,329,477 ops/sec ±2.21% (85 runs sampled)
+
+ fastest is kind-of (by 632% avg)
+
+# object-plain (47 bytes)
+ kind-of x 7,085,155 ops/sec ±1.05% (88 runs sampled)
+ lib-type-of x 8,870,930 ops/sec ±1.06% (83 runs sampled)
+ lib-typeof x 8,716,024 ops/sec ±1.05% (87 runs sampled)
+
+ fastest is lib-type-of (by 112% avg)
+
+# regex (25 bytes)
+ kind-of x 14,196,052 ops/sec ±1.65% (84 runs sampled)
+ lib-type-of x 9,554,164 ops/sec ±1.25% (88 runs sampled)
+ lib-typeof x 8,359,691 ops/sec ±1.07% (87 runs sampled)
+
+ fastest is kind-of (by 158% avg)
+
+# string (33 bytes)
+ kind-of x 16,131,428 ops/sec ±1.41% (85 runs sampled)
+ lib-type-of x 7,273,172 ops/sec ±1.05% (87 runs sampled)
+ lib-typeof x 7,382,635 ops/sec ±1.17% (85 runs sampled)
+
+ fastest is kind-of (by 220% avg)
+
+# symbol (34 bytes)
+ kind-of x 17,011,537 ops/sec ±1.24% (86 runs sampled)
+ lib-type-of x 3,492,454 ops/sec ±1.23% (89 runs sampled)
+ lib-typeof x 7,471,235 ops/sec ±2.48% (87 runs sampled)
+
+ fastest is kind-of (by 310% avg)
+
+# template-strings (36 bytes)
+ kind-of x 15,434,250 ops/sec ±1.46% (83 runs sampled)
+ lib-type-of x 7,157,907 ops/sec ±0.97% (87 runs sampled)
+ lib-typeof x 7,517,986 ops/sec ±0.92% (86 runs sampled)
+
+ fastest is kind-of (by 210% avg)
+
+# undefined (29 bytes)
+ kind-of x 19,167,115 ops/sec ±1.71% (87 runs sampled)
+ lib-type-of x 15,477,740 ops/sec ±1.63% (85 runs sampled)
+ lib-typeof x 19,075,495 ops/sec ±1.17% (83 runs sampled)
+
+ fastest is lib-typeof,kind-of
+
+```
+
+## Optimizations
+
+In 7 out of 8 cases, this library is 2x-10x faster than other top libraries included in the benchmarks. There are a few things that lead to this performance advantage, none of them hard and fast rules, but all of them simple and repeatable in almost any code library:
+
+1. Optimize around the fastest and most common use cases first. Of course, this will change from project-to-project, but I took some time to understand how and why `typeof` checks were being used in my own libraries and other libraries I use a lot.
+2. Optimize around bottlenecks - In other words, the order in which conditionals are implemented is significant, because each check is only as fast as the failing checks that came before it. Here, the biggest bottleneck by far is checking for plain objects (an object that was created by the `Object` constructor). I opted to make this check happen by process of elimination rather than brute force up front (e.g. by using something like `val.constructor.name`), so that every other type check would not be penalized it.
+3. Don't do uneccessary processing - why do `.slice(8, -1).toLowerCase();` just to get the word `regex`? It's much faster to do `if (type === '[object RegExp]') return 'regex'`
+4. There is no reason to make the code in a microlib as terse as possible, just to win points for making it shorter. It's always better to favor performant code over terse code. You will always only be using a single `require()` statement to use the library anyway, regardless of how the code is written.
+
+## Better type checking
+
+kind-of seems to be more consistently "correct" than other type checking libs I've looked at. For example, here are some differing results from other popular libs:
+
+### [typeof](https://github.com/CodingFu/typeof) lib
+
+Incorrectly identifies instances of custom constructors (pretty common):
+
+```js
+var typeOf = require('typeof');
+function Test() {}
+console.log(typeOf(new Test()));
+//=> 'test'
+```
+
+Returns `object` instead of `arguments`:
+
+```js
+function foo() {
+ console.log(typeOf(arguments)) //=> 'object'
+}
+foo();
+```
+
+### [type-of](https://github.com/ForbesLindesay/type-of) lib
+
+Incorrectly returns `object` for generator functions, buffers, `Map`, `Set`, `WeakMap` and `WeakSet`:
+
+```js
+function * foo() {}
+console.log(typeOf(foo));
+//=> 'object'
+console.log(typeOf(new Buffer('')));
+//=> 'object'
+console.log(typeOf(new Map()));
+//=> 'object'
+console.log(typeOf(new Set()));
+//=> 'object'
+console.log(typeOf(new WeakMap()));
+//=> 'object'
+console.log(typeOf(new WeakSet()));
+//=> 'object'
+```
+
+## About
+
+<details>
+<summary><strong>Contributing</strong></summary>
+
+Pull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new).
+
+</details>
+
+<details>
+<summary><strong>Running Tests</strong></summary>
+
+Running and reviewing unit tests is a great way to get familiarized with a library and its API. You can install dependencies and run tests with the following command:
+
+```sh
+$ npm install && npm test
+```
+
+</details>
+
+<details>
+<summary><strong>Building docs</strong></summary>
+
+_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_
+
+To generate the readme, run the following command:
+
+```sh
+$ npm install -g verbose/verb#dev verb-generate-readme && verb
+```
+
+</details>
+
+### Related projects
+
+You might also be interested in these projects:
+
+* [is-glob](https://www.npmjs.com/package/is-glob): Returns `true` if the given string looks like a glob pattern or an extglob pattern… [more](https://github.com/jonschlinkert/is-glob) | [homepage](https://github.com/jonschlinkert/is-glob "Returns `true` if the given string looks like a glob pattern or an extglob pattern. This makes it easy to create code that only uses external modules like node-glob when necessary, resulting in much faster code execution and initialization time, and a bet")
+* [is-number](https://www.npmjs.com/package/is-number): Returns true if the value is a number. comprehensive tests. | [homepage](https://github.com/jonschlinkert/is-number "Returns true if the value is a number. comprehensive tests.")
+* [is-primitive](https://www.npmjs.com/package/is-primitive): Returns `true` if the value is a primitive. | [homepage](https://github.com/jonschlinkert/is-primitive "Returns `true` if the value is a primitive. ")
+
+### Contributors
+
+| **Commits** | **Contributor** |
+| --- | --- |
+| 98 | [jonschlinkert](https://github.com/jonschlinkert) |
+| 3 | [aretecode](https://github.com/aretecode) |
+| 2 | [miguelmota](https://github.com/miguelmota) |
+| 1 | [dtothefp](https://github.com/dtothefp) |
+| 1 | [ianstormtaylor](https://github.com/ianstormtaylor) |
+| 1 | [ksheedlo](https://github.com/ksheedlo) |
+| 1 | [pdehaan](https://github.com/pdehaan) |
+| 1 | [laggingreflex](https://github.com/laggingreflex) |
+| 1 | [charlike-old](https://github.com/charlike-old) |
+
+### Author
+
+**Jon Schlinkert**
+
+* [linkedin/in/jonschlinkert](https://linkedin.com/in/jonschlinkert)
+* [github/jonschlinkert](https://github.com/jonschlinkert)
+* [twitter/jonschlinkert](https://twitter.com/jonschlinkert)
+
+### License
+
+Copyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert).
+Released under the [MIT License](LICENSE).
+
+***
+
+_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.6.0, on December 01, 2017._ \ No newline at end of file
diff --git a/node_modules/section-matter/node_modules/kind-of/index.js b/node_modules/section-matter/node_modules/kind-of/index.js
new file mode 100644
index 00000000..aa2bb394
--- /dev/null
+++ b/node_modules/section-matter/node_modules/kind-of/index.js
@@ -0,0 +1,129 @@
+var toString = Object.prototype.toString;
+
+module.exports = function kindOf(val) {
+ if (val === void 0) return 'undefined';
+ if (val === null) return 'null';
+
+ var type = typeof val;
+ if (type === 'boolean') return 'boolean';
+ if (type === 'string') return 'string';
+ if (type === 'number') return 'number';
+ if (type === 'symbol') return 'symbol';
+ if (type === 'function') {
+ return isGeneratorFn(val) ? 'generatorfunction' : 'function';
+ }
+
+ if (isArray(val)) return 'array';
+ if (isBuffer(val)) return 'buffer';
+ if (isArguments(val)) return 'arguments';
+ if (isDate(val)) return 'date';
+ if (isError(val)) return 'error';
+ if (isRegexp(val)) return 'regexp';
+
+ switch (ctorName(val)) {
+ case 'Symbol': return 'symbol';
+ case 'Promise': return 'promise';
+
+ // Set, Map, WeakSet, WeakMap
+ case 'WeakMap': return 'weakmap';
+ case 'WeakSet': return 'weakset';
+ case 'Map': return 'map';
+ case 'Set': return 'set';
+
+ // 8-bit typed arrays
+ case 'Int8Array': return 'int8array';
+ case 'Uint8Array': return 'uint8array';
+ case 'Uint8ClampedArray': return 'uint8clampedarray';
+
+ // 16-bit typed arrays
+ case 'Int16Array': return 'int16array';
+ case 'Uint16Array': return 'uint16array';
+
+ // 32-bit typed arrays
+ case 'Int32Array': return 'int32array';
+ case 'Uint32Array': return 'uint32array';
+ case 'Float32Array': return 'float32array';
+ case 'Float64Array': return 'float64array';
+ }
+
+ if (isGeneratorObj(val)) {
+ return 'generator';
+ }
+
+ // Non-plain objects
+ type = toString.call(val);
+ switch (type) {
+ case '[object Object]': return 'object';
+ // iterators
+ case '[object Map Iterator]': return 'mapiterator';
+ case '[object Set Iterator]': return 'setiterator';
+ case '[object String Iterator]': return 'stringiterator';
+ case '[object Array Iterator]': return 'arrayiterator';
+ }
+
+ // other
+ return type.slice(8, -1).toLowerCase().replace(/\s/g, '');
+};
+
+function ctorName(val) {
+ return val.constructor ? val.constructor.name : null;
+}
+
+function isArray(val) {
+ if (Array.isArray) return Array.isArray(val);
+ return val instanceof Array;
+}
+
+function isError(val) {
+ return val instanceof Error || (typeof val.message === 'string' && val.constructor && typeof val.constructor.stackTraceLimit === 'number');
+}
+
+function isDate(val) {
+ if (val instanceof Date) return true;
+ return typeof val.toDateString === 'function'
+ && typeof val.getDate === 'function'
+ && typeof val.setDate === 'function';
+}
+
+function isRegexp(val) {
+ if (val instanceof RegExp) return true;
+ return typeof val.flags === 'string'
+ && typeof val.ignoreCase === 'boolean'
+ && typeof val.multiline === 'boolean'
+ && typeof val.global === 'boolean';
+}
+
+function isGeneratorFn(name, val) {
+ return ctorName(name) === 'GeneratorFunction';
+}
+
+function isGeneratorObj(val) {
+ return typeof val.throw === 'function'
+ && typeof val.return === 'function'
+ && typeof val.next === 'function';
+}
+
+function isArguments(val) {
+ try {
+ if (typeof val.length === 'number' && typeof val.callee === 'function') {
+ return true;
+ }
+ } catch (err) {
+ if (err.message.indexOf('callee') !== -1) {
+ return true;
+ }
+ }
+ return false;
+}
+
+/**
+ * If you need to support Safari 5-7 (8-10 yr-old browser),
+ * take a look at https://github.com/feross/is-buffer
+ */
+
+function isBuffer(val) {
+ if (val.constructor && typeof val.constructor.isBuffer === 'function') {
+ return val.constructor.isBuffer(val);
+ }
+ return false;
+}
diff --git a/node_modules/section-matter/node_modules/kind-of/package.json b/node_modules/section-matter/node_modules/kind-of/package.json
new file mode 100644
index 00000000..73d70aee
--- /dev/null
+++ b/node_modules/section-matter/node_modules/kind-of/package.json
@@ -0,0 +1,88 @@
+{
+ "name": "kind-of",
+ "description": "Get the native type of a value.",
+ "version": "6.0.2",
+ "homepage": "https://github.com/jonschlinkert/kind-of",
+ "author": "Jon Schlinkert (https://github.com/jonschlinkert)",
+ "contributors": [
+ "David Fox-Powell (https://dtothefp.github.io/me)",
+ "James (https://twitter.com/aretecode)",
+ "Jon Schlinkert (http://twitter.com/jonschlinkert)",
+ "Ken Sheedlo (kensheedlo.com)",
+ "laggingreflex (https://github.com/laggingreflex)",
+ "Miguel Mota (https://miguelmota.com)",
+ "Peter deHaan (http://about.me/peterdehaan)",
+ "tunnckoCore (https://i.am.charlike.online)"
+ ],
+ "repository": "jonschlinkert/kind-of",
+ "bugs": {
+ "url": "https://github.com/jonschlinkert/kind-of/issues"
+ },
+ "license": "MIT",
+ "files": [
+ "index.js"
+ ],
+ "main": "index.js",
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "scripts": {
+ "test": "mocha",
+ "prepublish": "browserify -o browser.js -e index.js -s index --bare"
+ },
+ "devDependencies": {
+ "benchmarked": "^2.0.0",
+ "browserify": "^14.4.0",
+ "gulp-format-md": "^1.0.0",
+ "mocha": "^4.0.1",
+ "write": "^1.0.3"
+ },
+ "keywords": [
+ "arguments",
+ "array",
+ "boolean",
+ "check",
+ "date",
+ "function",
+ "is",
+ "is-type",
+ "is-type-of",
+ "kind",
+ "kind-of",
+ "number",
+ "object",
+ "of",
+ "regexp",
+ "string",
+ "test",
+ "type",
+ "type-of",
+ "typeof",
+ "types"
+ ],
+ "verb": {
+ "toc": false,
+ "layout": "default",
+ "tasks": [
+ "readme"
+ ],
+ "plugins": [
+ "gulp-format-md"
+ ],
+ "lint": {
+ "reflinks": true
+ },
+ "related": {
+ "list": [
+ "is-glob",
+ "is-number",
+ "is-primitive"
+ ]
+ },
+ "reflinks": [
+ "type-of",
+ "typeof",
+ "verb"
+ ]
+ }
+}
diff --git a/node_modules/section-matter/package.json b/node_modules/section-matter/package.json
new file mode 100644
index 00000000..a706c6d0
--- /dev/null
+++ b/node_modules/section-matter/package.json
@@ -0,0 +1,55 @@
+{
+ "name": "section-matter",
+ "description": "Like front-matter, but supports multiple sections in a document.",
+ "version": "1.0.0",
+ "homepage": "https://github.com/jonschlinkert/section-matter",
+ "author": "Jon Schlinkert (https://github.com/jonschlinkert)",
+ "repository": "jonschlinkert/section-matter",
+ "bugs": {
+ "url": "https://github.com/jonschlinkert/section-matter/issues"
+ },
+ "license": "MIT",
+ "files": [
+ "index.js"
+ ],
+ "main": "index.js",
+ "engines": {
+ "node": ">=4"
+ },
+ "scripts": {
+ "test": "mocha"
+ },
+ "dependencies": {
+ "extend-shallow": "^2.0.1",
+ "kind-of": "^6.0.0"
+ },
+ "devDependencies": {
+ "gulp-format-md": "^1.0.0",
+ "js-yaml": "^3.10.0",
+ "mocha": "^4.0.1"
+ },
+ "keywords": [
+ "matter",
+ "section"
+ ],
+ "verb": {
+ "toc": false,
+ "layout": "default",
+ "tasks": [
+ "readme"
+ ],
+ "plugins": [
+ "gulp-format-md"
+ ],
+ "related": {
+ "list": [
+ "gray-matter",
+ "assemble",
+ "verb"
+ ]
+ },
+ "lint": {
+ "reflinks": true
+ }
+ }
+}