Convert docs to docsy

This commit is contained in:
Phillip Wittrock
2020-06-07 21:07:46 -07:00
parent 25a38ad2b6
commit 42497c664f
11469 changed files with 816051 additions and 4557 deletions

21
site/node_modules/cosmiconfig/lib/loadPackageProp.js generated vendored Normal file
View File

@@ -0,0 +1,21 @@
'use strict';
var path = require('path');
var readFile = require('./readFile');
var parseJson = require('./parseJson');
module.exports = function (packageDir, options) {
var packagePath = path.join(packageDir, 'package.json');
return readFile(packagePath).then(function (content) {
if (!content) return null;
var parsedContent = parseJson(content, packagePath);
var packagePropValue = parsedContent[options.packageProp];
if (!packagePropValue) return null;
return {
config: packagePropValue,
filepath: packagePath,
};
});
};