diff --git a/.coveralls.yml b/.coveralls.yml new file mode 100644 index 00000000..3255b143 --- /dev/null +++ b/.coveralls.yml @@ -0,0 +1 @@ +service_name: travis-ci diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 00000000..4d9e87f5 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,4 @@ +@types/* linguist-generated=true +dist/* linguist-generated=true +**/__snapshots__/* linguist-generated=true +**/examples/* linguist-generated=true diff --git a/.gitignore b/.gitignore new file mode 100644 index 00000000..ccdfc1e3 --- /dev/null +++ b/.gitignore @@ -0,0 +1,296 @@ +## Ignore Visual Studio temporary files, build results, and +## files generated by popular Visual Studio add-ons. + +# User-specific files +*.suo +*.user +*.userosscache +*.sln.docstates + +# User-specific files (MonoDevelop/Xamarin Studio) +*.userprefs + +# Build results +[Dd]ebug/ +[Dd]ebugPublic/ +[Rr]elease/ +[Rr]eleases/ +x64/ +x86/ +bld/ +[Bb]in/ +[Oo]bj/ +[Ll]og/ + +# Visual Studio 2015 cache/options directory +.vs/ +# Uncomment if you have tasks that create the project's static files in wwwroot +#wwwroot/ + +# MSTest test Results +[Tt]est[Rr]esult*/ +[Bb]uild[Ll]og.* + +# NUNIT +*.VisualState.xml +TestResult.xml + +# Build Results of an ATL Project +[Dd]ebugPS/ +[Rr]eleasePS/ +dlldata.c + +# DNX +project.lock.json +artifacts/ + +*_i.c +*_p.c +*_i.h +*.ilk +*.meta +*.obj +*.pch +*.pdb +*.pgc +*.pgd +*.rsp +*.sbr +*.tlb +*.tli +*.tlh +*.tmp +*.tmp_proj +*.log +*.vspscc +*.vssscc +.builds +*.pidb +*.svclog +*.scc + +# Chutzpah Test files +_Chutzpah* + +# Visual C++ cache files +ipch/ +*.aps +*.ncb +*.opendb +*.opensdf +*.sdf +*.cachefile +*.VC.db +*.VC.VC.opendb + +# Visual Studio profiler +*.psess +*.vsp +*.vspx +*.sap + +# TFS 2012 Local Workspace +$tf/ + +# Guidance Automation Toolkit +*.gpState + +# ReSharper is a .NET coding add-in +_ReSharper*/ +*.[Rr]e[Ss]harper +*.DotSettings.user + +# JustCode is a .NET coding add-in +.JustCode + +# TeamCity is a build add-in +_TeamCity* + +# DotCover is a Code Coverage Tool +*.dotCover + +# NCrunch +_NCrunch_* +.*crunch*.local.xml +nCrunchTemp_* + +# MightyMoose +*.mm.* +AutoTest.Net/ + +# Web workbench (sass) +.sass-cache/ + +# Installshield output folder +[Ee]xpress/ + +# DocProject is a documentation generator add-in +DocProject/buildhelp/ +DocProject/Help/*.HxT +DocProject/Help/*.HxC +DocProject/Help/*.hhc +DocProject/Help/*.hhk +DocProject/Help/*.hhp +DocProject/Help/Html2 +DocProject/Help/html + +# Click-Once directory +publish/ + +# Publish Web Output +*.[Pp]ublish.xml +*.azurePubxml +# TODO: Comment the next line if you want to checkin your web deploy settings +# but database connection strings (with potential passwords) will be unencrypted +*.pubxml +*.publishproj + +# Microsoft Azure Web App publish settings. Comment the next line if you want to +# checkin your Azure Web App publish settings, but sensitive information contained +# in these scripts will be unencrypted +PublishScripts/ + +# NuGet Packages +*.nupkg +# The packages folder can be ignored because of Package Restore +#**/packages/* +# except build/, which is used as an MSBuild target. +!**/packages/build/ +# Uncomment if necessary however generally it will be regenerated when needed +#!**/packages/repositories.config +# NuGet v3's project.json files produces more ignoreable files +*.nuget.props +*.nuget.targets + +# Microsoft Azure Build Output +csx/ +*.build.csdef + +# Microsoft Azure Emulator +ecf/ +rcf/ + +# Windows Store app package directories and files +AppPackages/ +BundleArtifacts/ +Package.StoreAssociation.xml +_pkginfo.txt + +# Visual Studio cache files +# files ending in .cache can be ignored +*.[Cc]ache +# but keep track of directories ending in .cache +!*.[Cc]ache/ + +# Others +ClientBin/ +~$* +*~ +*.dbmdl +*.dbproj.schemaview +*.pfx +*.publishsettings +node_modules/ +orleans.codegen.cs + +# Since there are multiple workflows, uncomment next line to ignore bower_components +# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) +#bower_components/ + +# RIA/Silverlight projects +Generated_Code/ + +# Backup & report files from converting an old project file +# to a newer Visual Studio version. Backup files are not needed, +# because we have git ;-) +_UpgradeReport_Files/ +Backup*/ +UpgradeLog*.XML +UpgradeLog*.htm + +# SQL Server files +*.mdf +*.ldf + +# Business Intelligence projects +*.rdl.data +*.bim.layout +*.bim_*.settings + +# Microsoft Fakes +FakesAssemblies/ + +# GhostDoc plugin setting file +*.GhostDoc.xml + +# Node.js Tools for Visual Studio +.ntvs_analysis.dat + +# Visual Studio 6 build log +*.plg + +# Visual Studio 6 workspace options file +*.opt + +# Visual Studio LightSwitch build output +**/*.HTMLClient/GeneratedArtifacts +**/*.DesktopClient/GeneratedArtifacts +**/*.DesktopClient/ModelManifest.xml +**/*.Server/GeneratedArtifacts +**/*.Server/ModelManifest.xml +_Pvt_Extensions + +# Paket dependency manager +.paket/paket.exe +paket-files/ + +# FAKE - F# Make +.fake/ + +# JetBrains Rider +.idea/ +*.sln.iml +yarn.lock + +packages/react-forms-test + +dist +@types +package-lock.json + +# MacOS +.DS_Store + +# Ignore Rush temporary files +/common/temp/** + +**/webpack.config.js + +**/*.js.map + +_src +coverage + +# Rush files +**/*.build.error.log +**/*.build.log +/common/apiDocs/json/** +/common/last-install.flag +/common/last-install.log +/common/local-npm +/common/local-npm/** +/common/local-rush +/common/local-rush/** +/common/npm-cache +/common/npm-cache/** +/common/npm-local +/common/npm-local/** +/common/npm-tmp +/common/npm-tmp/** +/common/rush-link.json +/common/rush-recycler +package-deps.json + +# Tests +**/tests/cases/__tests__/*.test.ts + diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 00000000..3206e0a7 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,16 @@ +language: node_js +notifications: + email: + on_success: never + on_failure: change +branches: + only: + - master + - dev + - /^v\d+\.\d+(\.\d+)?(-\S*)?$/ +node_js: +- "node" +script: +- npm run rush-install +- npm run rush-rebuild +- npm run test-ci diff --git a/common/config/rush/command-line.json b/common/config/rush/command-line.json new file mode 100644 index 00000000..c77828a0 --- /dev/null +++ b/common/config/rush/command-line.json @@ -0,0 +1,12 @@ +{ + "$schema": "../../schemas/command-line.schema.json", + "customCommands": [ + { + "name": "test-ci", + "documentation": "Testing packages", + "parallelized": false, + "summary": "Testing packages" + } + ], + "customOptions": {} +} diff --git a/common/config/rush/npm-shrinkwrap.json b/common/config/rush/npm-shrinkwrap.json new file mode 100644 index 00000000..04004c3b --- /dev/null +++ b/common/config/rush/npm-shrinkwrap.json @@ -0,0 +1,5074 @@ +{ + "name": "rush-common", + "version": "0.0.0", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "@babel/code-frame": { + "version": "7.0.0-beta.36", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.0.0-beta.36.tgz", + "integrity": "sha512-sW77BFwJ48YvQp3Gzz5xtAUiXuYOL2aMJKDwiaY3OcvdqBFurtYfOpSa4QrNyDxmOGRFSYzUpabU2m9QrlWE7w==", + "requires": { + "chalk": "2.3.0", + "esutils": "2.0.2", + "js-tokens": "3.0.2" + } + }, + "@rush-temp/test-generator-cli": { + "version": "file:projects/test-generator-cli.tgz", + "integrity": "sha1-6X6rHJJU5+82zdF9bZ62CZYrxzk=", + "requires": { + "@types/fs-extra": "4.0.7", + "@types/handlebars": "4.0.36", + "@types/yargs": "10.0.0", + "fast-glob": "1.0.1", + "fs-extra": "4.0.3", + "handlebars": "4.0.11", + "simplr-logger": "1.0.1", + "simplr-tslint": "0.0.1", + "tslint": "5.8.0", + "typescript": "2.6.2", + "yargs": "10.0.3" + } + }, + "@rush-temp/ts-docs-gen": { + "version": "file:projects/ts-docs-gen.tgz", + "integrity": "sha1-VpmYmmPCGxgpL+NQ/+Q7RbokkUI=", + "requires": { + "@simplrjs/markdown": "1.0.7", + "@types/fs-extra": "5.0.0", + "@types/jest": "22.0.0", + "@types/sinon": "4.1.2", + "fast-glob": "1.0.1", + "fs-extra": "5.0.0", + "jest": "22.0.4", + "simplr-logger": "1.0.1", + "simplr-tslint": "0.0.1", + "sinon": "4.1.3", + "ts-extractor": "3.1.1", + "ts-jest": "22.0.0", + "tslint": "5.8.0", + "typescript": "2.6.2" + }, + "dependencies": { + "@types/fs-extra": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/@types/fs-extra/-/fs-extra-5.0.0.tgz", + "integrity": "sha512-qtxDULQKUenuaDLW003CgC+0T0eiAfH3BrH+vSt87GLzbz5EZ6Ox6mv9rMttvhDOatbb9nYh0E1m7ydoYwUrAg==", + "requires": { + "@types/node": "8.5.2" + } + }, + "fs-extra": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-5.0.0.tgz", + "integrity": "sha512-66Pm4RYbjzdyeuqudYqhFiNBbCIuI9kgRqLPSHIlXHidW8NIQtVdkM1yeZ4lXwuhbTETv3EUGMNHAAw6hiundQ==", + "requires": { + "graceful-fs": "4.1.11", + "jsonfile": "4.0.0", + "universalify": "0.1.1" + } + } + } + }, + "@simplrjs/markdown": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/@simplrjs/markdown/-/markdown-1.0.7.tgz", + "integrity": "sha512-QIIyLpb37GHpQD+7a5FCz/cxB2RVBp8mn2rSoFMkC0ZZAFIsw1UEmy7B9nPTPW923VNW5w9+4GnVqCUqkvCqfQ==", + "requires": { + "@types/string": "0.0.29", + "string": "3.3.3" + } + }, + "@types/fs-extra": { + "version": "4.0.7", + "resolved": "https://registry.npmjs.org/@types/fs-extra/-/fs-extra-4.0.7.tgz", + "integrity": "sha512-BN48b/2F3kL0Ual7tjcHjj0Fl+nuYKtHa0G/xT3Q43HuCpN7rQD5vIx6Aqnl9x10oBI5xMJh8Ly+FQpP205JlA==", + "requires": { + "@types/node": "8.5.2" + } + }, + "@types/handlebars": { + "version": "4.0.36", + "resolved": "https://registry.npmjs.org/@types/handlebars/-/handlebars-4.0.36.tgz", + "integrity": "sha512-LjNiTX7TY7wtuC6y3QwC93hKMuqYhgV9A1uXBKNvZtVC8ZvyWAjZkJ5BvT0K7RKqORRYRLMrqCxpw5RgS+MdrQ==" + }, + "@types/jest": { + "version": "22.0.0", + "resolved": "https://registry.npmjs.org/@types/jest/-/jest-22.0.0.tgz", + "integrity": "sha512-YnvduQPdRtIfvBLqfs6am0iz/07sqd/VYyPoqLzyZAYGyjokJDiE+LCgqX13ef8PNOWG5+Opbcy9gn5ymSIHCg==" + }, + "@types/node": { + "version": "8.5.2", + "resolved": "https://registry.npmjs.org/@types/node/-/node-8.5.2.tgz", + "integrity": "sha512-KA4GKOpgXnrqEH2eCVhiv2CsxgXGQJgV1X0vsGlh+WCnxbeAE1GT44ZsTU1IN5dEeV/gDupKa7gWo08V5IxWVQ==" + }, + "@types/sinon": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/@types/sinon/-/sinon-4.1.2.tgz", + "integrity": "sha512-fL6bJHYRzbw/7ofbKiJ65SOAasoe5mZhHNSYKxWsF3sGl/arhRwDPwXJqM1xofKNTQD14HNX9VruicM7pm++mQ==" + }, + "@types/string": { + "version": "0.0.29", + "resolved": "https://registry.npmjs.org/@types/string/-/string-0.0.29.tgz", + "integrity": "sha512-p8YTvb6vTWL38JxSe1rCduwP2l0jNRZpHlDUWqLt5A3F4SOc7yBPPd3jBiSk3b66urjs2tFM2QOhf4yEzz9wiQ==" + }, + "@types/yargs": { + "version": "10.0.0", + "resolved": "https://registry.npmjs.org/@types/yargs/-/yargs-10.0.0.tgz", + "integrity": "sha512-c1v82fFxticW/Iy49M8tbYy/4OTxuNAZHBVJTFlTYiW6JZrZxA0Yepj8c8qHgS3ZUxqW8M49awWaaF1DUJf/Ow==" + }, + "abab": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/abab/-/abab-1.0.4.tgz", + "integrity": "sha1-X6rZwsB/YN12dw9xzwJbYqY8/U4=" + }, + "acorn": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-5.3.0.tgz", + "integrity": "sha512-Yej+zOJ1Dm/IMZzzj78OntP/r3zHEaKcyNoU2lAaxPtrseM6rF0xwqoz5Q5ysAiED9hTjI2hgtvLXitlCN1/Ug==" + }, + "acorn-globals": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/acorn-globals/-/acorn-globals-4.1.0.tgz", + "integrity": "sha512-KjZwU26uG3u6eZcfGbTULzFcsoz6pegNKtHPksZPOUsiKo5bUmiBPa38FuHZ/Eun+XYh/JCCkS9AS3Lu4McQOQ==", + "requires": { + "acorn": "5.3.0" + } + }, + "ajv": { + "version": "5.5.2", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-5.5.2.tgz", + "integrity": "sha1-c7Xuyj+rZT49P5Qis0GtQiBdyWU=", + "requires": { + "co": "4.6.0", + "fast-deep-equal": "1.0.0", + "fast-json-stable-stringify": "2.0.0", + "json-schema-traverse": "0.3.1" + } + }, + "amdefine": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/amdefine/-/amdefine-1.0.1.tgz", + "integrity": "sha1-SlKCrBZHKek2Gbz9OtFR+BfOkfU=" + }, + "ansi-escapes": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-3.0.0.tgz", + "integrity": "sha512-O/klc27mWNUigtv0F8NJWbLF00OcegQalkqKURWdosW08YZKi4m6CnSUSvIZG1otNJbTWhN01Hhz389DW7mvDQ==" + }, + "ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=" + }, + "ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4=" + }, + "anymatch": { + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-1.3.2.tgz", + "integrity": "sha512-0XNayC8lTHQ2OI8aljNCN3sSx6hsr/1+rlcDAotXJR7C1oZZHCNsfpbKwMjRA3Uqb5tF1Rae2oloTr4xpq+WjA==", + "requires": { + "micromatch": "2.3.11", + "normalize-path": "2.1.1" + }, + "dependencies": { + "arr-diff": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-2.0.0.tgz", + "integrity": "sha1-jzuCf5Vai9ZpaX5KQlasPOrjVs8=", + "requires": { + "arr-flatten": "1.1.0" + } + }, + "array-unique": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.2.1.tgz", + "integrity": "sha1-odl8yvy8JiXMcPrc6zalDFiwGlM=" + }, + "braces": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/braces/-/braces-1.8.5.tgz", + "integrity": "sha1-uneWLhLf+WnWt2cR6RS3N4V79qc=", + "requires": { + "expand-range": "1.8.2", + "preserve": "0.2.0", + "repeat-element": "1.1.2" + } + }, + "expand-brackets": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-0.1.5.tgz", + "integrity": "sha1-3wcoTjQqgHzXM6xa9yQR5YHRF3s=", + "requires": { + "is-posix-bracket": "0.1.1" + } + }, + "extglob": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-0.3.2.tgz", + "integrity": "sha1-Lhj/PS9JqydlzskCPwEdqo2DSaE=", + "requires": { + "is-extglob": "1.0.0" + } + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=" + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "requires": { + "is-extglob": "1.0.0" + } + }, + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + }, + "micromatch": { + "version": "2.3.11", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-2.3.11.tgz", + "integrity": "sha1-hmd8l9FyCzY0MdBNDRUpO9OMFWU=", + "requires": { + "arr-diff": "2.0.0", + "array-unique": "0.2.1", + "braces": "1.8.5", + "expand-brackets": "0.1.5", + "extglob": "0.3.2", + "filename-regex": "2.0.1", + "is-extglob": "1.0.0", + "is-glob": "2.0.1", + "kind-of": "3.2.2", + "normalize-path": "2.1.1", + "object.omit": "2.0.1", + "parse-glob": "3.0.4", + "regex-cache": "0.4.4" + } + } + } + }, + "append-transform": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/append-transform/-/append-transform-0.4.0.tgz", + "integrity": "sha1-126/jKlNJ24keja61EpLdKthGZE=", + "requires": { + "default-require-extensions": "1.0.0" + } + }, + "argparse": { + "version": "1.0.9", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.9.tgz", + "integrity": "sha1-c9g7wmP4bpf4zE9rrhsOkKfSLIY=", + "requires": { + "sprintf-js": "1.0.3" + } + }, + "arr-diff": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-4.0.0.tgz", + "integrity": "sha1-1kYQdP6/7HHn4VI1dhoyml3HxSA=" + }, + "arr-flatten": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/arr-flatten/-/arr-flatten-1.1.0.tgz", + "integrity": "sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg==" + }, + "arr-union": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/arr-union/-/arr-union-3.1.0.tgz", + "integrity": "sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ=" + }, + "array-equal": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/array-equal/-/array-equal-1.0.0.tgz", + "integrity": "sha1-jCpe8kcv2ep0KwTHenUJO6J1fJM=" + }, + "array-filter": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/array-filter/-/array-filter-0.0.1.tgz", + "integrity": "sha1-fajPLiZijtcygDWB/SH2fKzS7uw=" + }, + "array-map": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/array-map/-/array-map-0.0.0.tgz", + "integrity": "sha1-iKK6tz0c97zVwbEYoAP2b2ZfpmI=" + }, + "array-reduce": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/array-reduce/-/array-reduce-0.0.0.tgz", + "integrity": "sha1-FziZ0//Rx9k4PkR5Ul2+J4yrXys=" + }, + "array-unique": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz", + "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=" + }, + "arrify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/arrify/-/arrify-1.0.1.tgz", + "integrity": "sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0=" + }, + "asn1": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.3.tgz", + "integrity": "sha1-2sh4dxPJlmhJ/IGAd36+nB3fO4Y=" + }, + "assert-plus": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", + "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=" + }, + "assign-symbols": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/assign-symbols/-/assign-symbols-1.0.0.tgz", + "integrity": "sha1-WWZ/QfrdTyDMvCu5a41Pf3jsA2c=" + }, + "astral-regex": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz", + "integrity": "sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg==" + }, + "async": { + "version": "1.5.2", + "resolved": "https://registry.npmjs.org/async/-/async-1.5.2.tgz", + "integrity": "sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo=" + }, + "async-each": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/async-each/-/async-each-1.0.1.tgz", + "integrity": "sha1-GdOGodntxufByF04iu28xW0zYC0=" + }, + "asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=" + }, + "atob": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/atob/-/atob-2.0.3.tgz", + "integrity": "sha1-GcenYEc3dEaPILLS0DNyrX1Mv10=" + }, + "aws-sign2": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", + "integrity": "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=" + }, + "aws4": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.6.0.tgz", + "integrity": "sha1-g+9cqGCysy5KDe7e6MdxudtXRx4=" + }, + "babel-code-frame": { + "version": "6.26.0", + "resolved": "https://registry.npmjs.org/babel-code-frame/-/babel-code-frame-6.26.0.tgz", + "integrity": "sha1-Y/1D99weO7fONZR9uP42mj9Yx0s=", + "requires": { + "chalk": "1.1.3", + "esutils": "2.0.2", + "js-tokens": "3.0.2" + }, + "dependencies": { + "chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", + "requires": { + "ansi-styles": "2.2.1", + "escape-string-regexp": "1.0.5", + "has-ansi": "2.0.0", + "strip-ansi": "3.0.1", + "supports-color": "2.0.0" + } + } + } + }, + "babel-core": { + "version": "6.26.0", + "resolved": "https://registry.npmjs.org/babel-core/-/babel-core-6.26.0.tgz", + "integrity": "sha1-rzL3izGm/O8RnIew/Y2XU/A6C7g=", + "requires": { + "babel-code-frame": "6.26.0", + "babel-generator": "6.26.0", + "babel-helpers": "6.24.1", + "babel-messages": "6.23.0", + "babel-register": "6.26.0", + "babel-runtime": "6.26.0", + "babel-template": "6.26.0", + "babel-traverse": "6.26.0", + "babel-types": "6.26.0", + "babylon": "6.18.0", + "convert-source-map": "1.5.1", + "debug": "2.6.9", + "json5": "0.5.1", + "lodash": "4.17.4", + "minimatch": "3.0.4", + "path-is-absolute": "1.0.1", + "private": "0.1.8", + "slash": "1.0.0", + "source-map": "0.5.7" + } + }, + "babel-generator": { + "version": "6.26.0", + "resolved": "https://registry.npmjs.org/babel-generator/-/babel-generator-6.26.0.tgz", + "integrity": "sha1-rBriAHC3n248odMmlhMFN3TyDcU=", + "requires": { + "babel-messages": "6.23.0", + "babel-runtime": "6.26.0", + "babel-types": "6.26.0", + "detect-indent": "4.0.0", + "jsesc": "1.3.0", + "lodash": "4.17.4", + "source-map": "0.5.7", + "trim-right": "1.0.1" + } + }, + "babel-helpers": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-helpers/-/babel-helpers-6.24.1.tgz", + "integrity": "sha1-NHHenK7DiOXIUOWX5Yom3fN2ArI=", + "requires": { + "babel-runtime": "6.26.0", + "babel-template": "6.26.0" + } + }, + "babel-jest": { + "version": "22.0.4", + "resolved": "https://registry.npmjs.org/babel-jest/-/babel-jest-22.0.4.tgz", + "integrity": "sha512-/Yt61fUpdFjetYlnpj280BPKEsPnK4mqzxDdo8DybPvrPNrLurbAF/WBjn2nnoi1Hc2Ippsf12/aOp8ys/Vl1A==", + "requires": { + "babel-plugin-istanbul": "4.1.5", + "babel-preset-jest": "22.0.3" + } + }, + "babel-messages": { + "version": "6.23.0", + "resolved": "https://registry.npmjs.org/babel-messages/-/babel-messages-6.23.0.tgz", + "integrity": "sha1-8830cDhYA1sqKVHG7F7fbGLyYw4=", + "requires": { + "babel-runtime": "6.26.0" + } + }, + "babel-plugin-istanbul": { + "version": "4.1.5", + "resolved": "https://registry.npmjs.org/babel-plugin-istanbul/-/babel-plugin-istanbul-4.1.5.tgz", + "integrity": "sha1-Z2DN2Xf0EdPhdbsGTyvDJ9mbK24=", + "requires": { + "find-up": "2.1.0", + "istanbul-lib-instrument": "1.9.1", + "test-exclude": "4.1.1" + } + }, + "babel-plugin-jest-hoist": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-22.0.3.tgz", + "integrity": "sha512-Z0pOZFs0xDctwF0bPEKrnAzvbbgDi2vDFbQ0EdofnLI2bOa3P1H66gNLb2vMJJaa00VDjfiGhIocsHvBkqtyEQ==" + }, + "babel-plugin-syntax-object-rest-spread": { + "version": "6.13.0", + "resolved": "https://registry.npmjs.org/babel-plugin-syntax-object-rest-spread/-/babel-plugin-syntax-object-rest-spread-6.13.0.tgz", + "integrity": "sha1-/WU28rzhODb/o6VFjEkDpZe7O/U=" + }, + "babel-plugin-transform-es2015-modules-commonjs": { + "version": "6.26.0", + "resolved": "https://registry.npmjs.org/babel-plugin-transform-es2015-modules-commonjs/-/babel-plugin-transform-es2015-modules-commonjs-6.26.0.tgz", + "integrity": "sha1-DYOUApt9xqvhqX7xgeAHWN0uXYo=", + "requires": { + "babel-plugin-transform-strict-mode": "6.24.1", + "babel-runtime": "6.26.0", + "babel-template": "6.26.0", + "babel-types": "6.26.0" + } + }, + "babel-plugin-transform-strict-mode": { + "version": "6.24.1", + "resolved": "https://registry.npmjs.org/babel-plugin-transform-strict-mode/-/babel-plugin-transform-strict-mode-6.24.1.tgz", + "integrity": "sha1-1fr3qleKZbvlkc9e2uBKDGcCB1g=", + "requires": { + "babel-runtime": "6.26.0", + "babel-types": "6.26.0" + } + }, + "babel-preset-jest": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/babel-preset-jest/-/babel-preset-jest-22.0.3.tgz", + "integrity": "sha512-FbMMniSMXFvkKldCf+e4Tuol/v3XMaIpIp8xiT1WFlEW3ZapTKDW9YgVt3hqcpZXsIGFf6eUF3Owxom7yFlI8w==", + "requires": { + "babel-plugin-jest-hoist": "22.0.3", + "babel-plugin-syntax-object-rest-spread": "6.13.0" + } + }, + "babel-register": { + "version": "6.26.0", + "resolved": "https://registry.npmjs.org/babel-register/-/babel-register-6.26.0.tgz", + "integrity": "sha1-btAhFz4vy0htestFxgCahW9kcHE=", + "requires": { + "babel-core": "6.26.0", + "babel-runtime": "6.26.0", + "core-js": "2.5.3", + "home-or-tmp": "2.0.0", + "lodash": "4.17.4", + "mkdirp": "0.5.1", + "source-map-support": "0.4.18" + }, + "dependencies": { + "source-map-support": { + "version": "0.4.18", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.4.18.tgz", + "integrity": "sha512-try0/JqxPLF9nOjvSta7tVondkP5dwgyLDjVoyMDlmjugT2lRZ1OfsrYTkCd2hkDnJTKRbO/Rl3orm8vlsUzbA==", + "requires": { + "source-map": "0.5.7" + } + } + } + }, + "babel-runtime": { + "version": "6.26.0", + "resolved": "https://registry.npmjs.org/babel-runtime/-/babel-runtime-6.26.0.tgz", + "integrity": "sha1-llxwWGaOgrVde/4E/yM3vItWR/4=", + "requires": { + "core-js": "2.5.3", + "regenerator-runtime": "0.11.1" + } + }, + "babel-template": { + "version": "6.26.0", + "resolved": "https://registry.npmjs.org/babel-template/-/babel-template-6.26.0.tgz", + "integrity": "sha1-3gPi0WOWsGn0bdn/+FIfsaDjXgI=", + "requires": { + "babel-runtime": "6.26.0", + "babel-traverse": "6.26.0", + "babel-types": "6.26.0", + "babylon": "6.18.0", + "lodash": "4.17.4" + } + }, + "babel-traverse": { + "version": "6.26.0", + "resolved": "https://registry.npmjs.org/babel-traverse/-/babel-traverse-6.26.0.tgz", + "integrity": "sha1-RqnL1+3MYsjlwGTi0tjQ9ANXZu4=", + "requires": { + "babel-code-frame": "6.26.0", + "babel-messages": "6.23.0", + "babel-runtime": "6.26.0", + "babel-types": "6.26.0", + "babylon": "6.18.0", + "debug": "2.6.9", + "globals": "9.18.0", + "invariant": "2.2.2", + "lodash": "4.17.4" + } + }, + "babel-types": { + "version": "6.26.0", + "resolved": "https://registry.npmjs.org/babel-types/-/babel-types-6.26.0.tgz", + "integrity": "sha1-o7Bz+Uq0nrb6Vc1lInozQ4BjJJc=", + "requires": { + "babel-runtime": "6.26.0", + "esutils": "2.0.2", + "lodash": "4.17.4", + "to-fast-properties": "1.0.3" + } + }, + "babylon": { + "version": "6.18.0", + "resolved": "https://registry.npmjs.org/babylon/-/babylon-6.18.0.tgz", + "integrity": "sha512-q/UEjfGJ2Cm3oKV71DJz9d25TPnq5rhBVL2Q4fA5wcC3jcrdn7+SssEybFIxwAvvP+YCsCYNKughoF33GxgycQ==" + }, + "balanced-match": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.0.tgz", + "integrity": "sha1-ibTRmasr7kneFk6gK4nORi1xt2c=" + }, + "base": { + "version": "0.11.2", + "resolved": "https://registry.npmjs.org/base/-/base-0.11.2.tgz", + "integrity": "sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg==", + "requires": { + "cache-base": "1.0.1", + "class-utils": "0.3.5", + "component-emitter": "1.2.1", + "define-property": "1.0.0", + "isobject": "3.0.1", + "mixin-deep": "1.3.0", + "pascalcase": "0.1.1" + } + }, + "bash-glob": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/bash-glob/-/bash-glob-1.0.2.tgz", + "integrity": "sha512-E0TTxH9T/tklSXt5R5X0zwxjW56su2VIE+sAruXbd8AtMjYZxtvioybVdptbRk0/0Nvdz0TVVShKhN9sH5dMpg==", + "requires": { + "async-each": "1.0.1", + "bash-path": "1.0.3", + "component-emitter": "1.2.1", + "cross-spawn": "5.1.0", + "extend-shallow": "2.0.1", + "is-extglob": "2.1.1", + "is-glob": "4.0.0" + } + }, + "bash-path": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/bash-path/-/bash-path-1.0.3.tgz", + "integrity": "sha512-mGrYvOa6yTY/qNCiZkPFJqWmODK68y6kmVRAJ1NNbWlNoJrUrsFxu7FU2EKg7gbrer6ttrKkF2s/E/lhRy7/OA==", + "requires": { + "arr-union": "3.1.0", + "is-windows": "1.0.1" + } + }, + "binary-extensions": { + "version": "1.11.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-1.11.0.tgz", + "integrity": "sha1-RqoXUftqL5PuXmibsQh9SxTGwgU=" + }, + "boom": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/boom/-/boom-4.3.1.tgz", + "integrity": "sha1-T4owBctKfjiJ90kDD9JbluAdLjE=", + "requires": { + "hoek": "4.2.0" + } + }, + "brace-expansion": { + "version": "1.1.8", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.8.tgz", + "integrity": "sha1-wHshHHyVLsH479Uad+8NHTmQopI=", + "requires": { + "balanced-match": "1.0.0", + "concat-map": "0.0.1" + } + }, + "braces": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/braces/-/braces-2.3.0.tgz", + "integrity": "sha512-P4O8UQRdGiMLWSizsApmXVQDBS6KCt7dSexgLKBmH5Hr1CZq7vsnscFh8oR1sP1ab1Zj0uCHCEzZeV6SfUf3rA==", + "requires": { + "arr-flatten": "1.1.0", + "array-unique": "0.3.2", + "define-property": "1.0.0", + "extend-shallow": "2.0.1", + "fill-range": "4.0.0", + "isobject": "3.0.1", + "repeat-element": "1.1.2", + "snapdragon": "0.8.1", + "snapdragon-node": "2.1.1", + "split-string": "3.1.0", + "to-regex": "3.0.1" + } + }, + "browser-process-hrtime": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/browser-process-hrtime/-/browser-process-hrtime-0.1.2.tgz", + "integrity": "sha1-Ql1opY00R/AqBKqJQYf86K+Le44=" + }, + "browser-resolve": { + "version": "1.11.2", + "resolved": "https://registry.npmjs.org/browser-resolve/-/browser-resolve-1.11.2.tgz", + "integrity": "sha1-j/CbCixCFxihBRwmCzLkj0QpOM4=", + "requires": { + "resolve": "1.1.7" + }, + "dependencies": { + "resolve": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.1.7.tgz", + "integrity": "sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs=" + } + } + }, + "bser": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/bser/-/bser-2.0.0.tgz", + "integrity": "sha1-mseNPtXZFYBP2HrLFYvHlxR6Fxk=", + "requires": { + "node-int64": "0.4.0" + } + }, + "builtin-modules": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-1.1.1.tgz", + "integrity": "sha1-Jw8HbFpywC9bZaR9+Uxf46J4iS8=" + }, + "cache-base": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/cache-base/-/cache-base-1.0.1.tgz", + "integrity": "sha512-AKcdTnFSWATd5/GCPRxr2ChwIJ85CeyrEyjRHlKxQ56d4XJMGym0uAiKn0xbLOGOl3+yRpOTi484dVCEc5AUzQ==", + "requires": { + "collection-visit": "1.0.0", + "component-emitter": "1.2.1", + "get-value": "2.0.6", + "has-value": "1.0.0", + "isobject": "3.0.1", + "set-value": "2.0.0", + "to-object-path": "0.3.0", + "union-value": "1.0.0", + "unset-value": "1.0.0" + } + }, + "call-me-maybe": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/call-me-maybe/-/call-me-maybe-1.0.1.tgz", + "integrity": "sha1-JtII6onje1y95gJQoV8DHBak1ms=" + }, + "callsites": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/callsites/-/callsites-2.0.0.tgz", + "integrity": "sha1-BuuE8A7qQT2oav/vrL/7Ngk7PFA=" + }, + "camelcase": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-4.1.0.tgz", + "integrity": "sha1-1UVjW+HjPFQmScaRc+Xeas+uNN0=" + }, + "caseless": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", + "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=" + }, + "chalk": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.3.0.tgz", + "integrity": "sha512-Az5zJR2CBujap2rqXGaJKaPHyJ0IrUimvYNX+ncCy8PJP4ltOGTrHUIo097ZaL2zMeKYpiCdqDvS6zdrTFok3Q==", + "requires": { + "ansi-styles": "3.2.0", + "escape-string-regexp": "1.0.5", + "supports-color": "4.5.0" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.0.tgz", + "integrity": "sha512-NnSOmMEYtVR2JVMIGTzynRkkaxtiq1xnFBcdQD/DnNCYPoEPsVJhM98BDyaoNOQIi7p4okdi3E27eN7GQbsUug==", + "requires": { + "color-convert": "1.9.1" + } + }, + "supports-color": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-4.5.0.tgz", + "integrity": "sha1-vnoN5ITexcXN34s9WRJQRJEvY1s=", + "requires": { + "has-flag": "2.0.0" + } + } + } + }, + "chokidar": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-1.7.0.tgz", + "integrity": "sha1-eY5ol3gVHIB2tLNg5e3SjNortGg=", + "requires": { + "anymatch": "1.3.2", + "async-each": "1.0.1", + "glob-parent": "2.0.0", + "inherits": "2.0.3", + "is-binary-path": "1.0.1", + "is-glob": "2.0.1", + "path-is-absolute": "1.0.1", + "readdirp": "2.1.0" + }, + "dependencies": { + "glob-parent": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-2.0.0.tgz", + "integrity": "sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg=", + "requires": { + "is-glob": "2.0.1" + } + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=" + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "requires": { + "is-extglob": "1.0.0" + } + } + } + }, + "ci-info": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-1.1.2.tgz", + "integrity": "sha512-uTGIPNx/nSpBdsF6xnseRXLLtfr9VLqkz8ZqHXr3Y7b6SftyRxBGjwMtJj1OhNbmlc1wZzLNAlAcvyIiE8a6ZA==" + }, + "class-utils": { + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/class-utils/-/class-utils-0.3.5.tgz", + "integrity": "sha1-F+eTEDdQ+WJ7IXbqNM/RtWWQPIA=", + "requires": { + "arr-union": "3.1.0", + "define-property": "0.2.5", + "isobject": "3.0.1", + "lazy-cache": "2.0.2", + "static-extend": "0.1.2" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "requires": { + "is-descriptor": "0.1.6" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==" + } + } + }, + "cliui": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-3.2.0.tgz", + "integrity": "sha1-EgYBU3qRbSmUD5NNo7SNWFo5IT0=", + "requires": { + "string-width": "1.0.2", + "strip-ansi": "3.0.1", + "wrap-ansi": "2.1.0" + }, + "dependencies": { + "string-width": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", + "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", + "requires": { + "code-point-at": "1.1.0", + "is-fullwidth-code-point": "1.0.0", + "strip-ansi": "3.0.1" + } + } + } + }, + "co": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/co/-/co-4.6.0.tgz", + "integrity": "sha1-bqa989hTrlTMuOR7+gvz+QMfsYQ=" + }, + "code-point-at": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", + "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=" + }, + "collection-visit": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/collection-visit/-/collection-visit-1.0.0.tgz", + "integrity": "sha1-S8A3PBZLwykbTTaMgpzxqApZ3KA=", + "requires": { + "map-visit": "1.0.0", + "object-visit": "1.0.1" + } + }, + "color-convert": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.1.tgz", + "integrity": "sha512-mjGanIiwQJskCC18rPR6OmrZ6fm2Lc7PeGFYwCmy5J34wC6F1PzdGL6xeMfmgicfYcNLGuVFA3WzXtIDCQSZxQ==", + "requires": { + "color-name": "1.1.3" + } + }, + "color-name": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", + "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=" + }, + "combined-stream": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.5.tgz", + "integrity": "sha1-k4NwpXtKUd6ix3wV1cX9+JUWQAk=", + "requires": { + "delayed-stream": "1.0.0" + } + }, + "commander": { + "version": "2.12.2", + "resolved": "https://registry.npmjs.org/commander/-/commander-2.12.2.tgz", + "integrity": "sha512-BFnaq5ZOGcDN7FlrtBT4xxkgIToalIIxwjxLWVJ8bGTpe1LroqMiqQXdA7ygc7CRvaYS+9zfPGFnJqFSayx+AA==" + }, + "component-emitter": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.2.1.tgz", + "integrity": "sha1-E3kY1teCg/ffemt8WmPhQOaUJeY=" + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" + }, + "content-type-parser": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/content-type-parser/-/content-type-parser-1.0.2.tgz", + "integrity": "sha512-lM4l4CnMEwOLHAHr/P6MEZwZFPJFtAAKgL6pogbXmVZggIqXhdB6RbBtPOTsw2FcXwYhehRGERJmRrjOiIB8pQ==" + }, + "convert-source-map": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.5.1.tgz", + "integrity": "sha1-uCeAl7m8IpNl3lxiz1/K7YtVmeU=" + }, + "copy-descriptor": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/copy-descriptor/-/copy-descriptor-0.1.1.tgz", + "integrity": "sha1-Z29us8OZl8LuGsOpJP1hJHSPV40=" + }, + "core-js": { + "version": "2.5.3", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.5.3.tgz", + "integrity": "sha1-isw4NFgk8W2DZbfJtCWRaOjtYD4=" + }, + "core-util-is": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", + "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" + }, + "cpx": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/cpx/-/cpx-1.5.0.tgz", + "integrity": "sha1-GFvgGFEdhycN7czCkxceN2VauI8=", + "requires": { + "babel-runtime": "6.26.0", + "chokidar": "1.7.0", + "duplexer": "0.1.1", + "glob": "7.1.2", + "glob2base": "0.0.12", + "minimatch": "3.0.4", + "mkdirp": "0.5.1", + "resolve": "1.5.0", + "safe-buffer": "5.1.1", + "shell-quote": "1.6.1", + "subarg": "1.0.0" + } + }, + "cross-spawn": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-5.1.0.tgz", + "integrity": "sha1-6L0O/uWPz/b4+UUQoKVUu/ojVEk=", + "requires": { + "lru-cache": "4.1.1", + "shebang-command": "1.2.0", + "which": "1.3.0" + } + }, + "cryptiles": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/cryptiles/-/cryptiles-3.1.2.tgz", + "integrity": "sha1-qJ+7Ig9c4l7FboxKqKT9e1sNKf4=", + "requires": { + "boom": "5.2.0" + }, + "dependencies": { + "boom": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/boom/-/boom-5.2.0.tgz", + "integrity": "sha512-Z5BTk6ZRe4tXXQlkqftmsAUANpXmuwlsF5Oov8ThoMbQRzdGTA1ngYRW160GexgOgjsFOKJz0LYhoNi+2AMBUw==", + "requires": { + "hoek": "4.2.0" + } + } + } + }, + "cssom": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/cssom/-/cssom-0.3.2.tgz", + "integrity": "sha1-uANhcMefB6kP8vFuIihAJ6JDhIs=" + }, + "cssstyle": { + "version": "0.2.37", + "resolved": "https://registry.npmjs.org/cssstyle/-/cssstyle-0.2.37.tgz", + "integrity": "sha1-VBCXI0yyUTyDzu06zdwn/yeYfVQ=", + "requires": { + "cssom": "0.3.2" + } + }, + "dashdash": { + "version": "1.14.1", + "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", + "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=", + "requires": { + "assert-plus": "1.0.0" + } + }, + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "requires": { + "ms": "2.0.0" + } + }, + "decamelize": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", + "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=" + }, + "decode-uri-component": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/decode-uri-component/-/decode-uri-component-0.2.0.tgz", + "integrity": "sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU=" + }, + "deep-is": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz", + "integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ=" + }, + "default-require-extensions": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/default-require-extensions/-/default-require-extensions-1.0.0.tgz", + "integrity": "sha1-836hXT4T/9m0N9M+GnW1+5eHTLg=", + "requires": { + "strip-bom": "2.0.0" + } + }, + "define-properties": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.1.2.tgz", + "integrity": "sha1-g6c/L+pWmJj7c3GTyPhzyvbUXJQ=", + "requires": { + "foreach": "2.0.5", + "object-keys": "1.0.11" + } + }, + "define-property": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-1.0.0.tgz", + "integrity": "sha1-dp66rz9KY6rTr56NMEybvnm/sOY=", + "requires": { + "is-descriptor": "1.0.2" + } + }, + "delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=" + }, + "detect-indent": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/detect-indent/-/detect-indent-4.0.0.tgz", + "integrity": "sha1-920GQ1LN9Docts5hnE7jqUdd4gg=", + "requires": { + "repeating": "2.0.1" + } + }, + "detect-newline": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/detect-newline/-/detect-newline-2.1.0.tgz", + "integrity": "sha1-9B8cEL5LAOh7XxPaaAdZ8sW/0+I=" + }, + "diff": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/diff/-/diff-3.4.0.tgz", + "integrity": "sha512-QpVuMTEoJMF7cKzi6bvWhRulU1fZqZnvyVQgNhPaxxuTYwyjn/j1v9falseQ/uXWwPnO56RBfwtg4h/EQXmucA==" + }, + "domexception": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/domexception/-/domexception-1.0.0.tgz", + "integrity": "sha512-WpwuBlZ2lQRFa4H/4w49deb9rJLot9KmqrKKjMc9qBl7CID+DdC2swoa34ccRl+anL2B6bLp6TjFdIdnzekMBQ==" + }, + "duplexer": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.1.tgz", + "integrity": "sha1-rOb/gIwc5mtX0ev5eXessCM0z8E=" + }, + "error-ex": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.1.tgz", + "integrity": "sha1-+FWobOYa3E6GIcPNoh56dhLDqNw=", + "requires": { + "is-arrayish": "0.2.1" + } + }, + "es-abstract": { + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.10.0.tgz", + "integrity": "sha512-/uh/DhdqIOSkAWifU+8nG78vlQxdLckUdI/sPgy0VhuXi2qJ7T8czBmqIYtLQVpCIFYafChnsRsB5pyb1JdmCQ==", + "requires": { + "es-to-primitive": "1.1.1", + "function-bind": "1.1.1", + "has": "1.0.1", + "is-callable": "1.1.3", + "is-regex": "1.0.4" + } + }, + "es-to-primitive": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.1.1.tgz", + "integrity": "sha1-RTVSSKiJeQNLZ5Lhm7gfK3l13Q0=", + "requires": { + "is-callable": "1.1.3", + "is-date-object": "1.0.1", + "is-symbol": "1.0.1" + } + }, + "es6-promise": { + "version": "4.2.2", + "resolved": "https://registry.npmjs.org/es6-promise/-/es6-promise-4.2.2.tgz", + "integrity": "sha512-LSas5vsuA6Q4nEdf9wokY5/AJYXry98i0IzXsv49rYsgDGDNDPbqAYR1Pe23iFxygfbGZNR/5VrHXBCh2BhvUQ==" + }, + "escape-string-regexp": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", + "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=" + }, + "escodegen": { + "version": "1.9.0", + "resolved": "https://registry.npmjs.org/escodegen/-/escodegen-1.9.0.tgz", + "integrity": "sha512-v0MYvNQ32bzwoG2OSFzWAkuahDQHK92JBN0pTAALJ4RIxEZe766QJPDR8Hqy7XNUy5K3fnVL76OqYAdc4TZEIw==", + "requires": { + "esprima": "3.1.3", + "estraverse": "4.2.0", + "esutils": "2.0.2", + "optionator": "0.8.2", + "source-map": "0.5.7" + }, + "dependencies": { + "esprima": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-3.1.3.tgz", + "integrity": "sha1-/cpRzuYTOJXjyI1TXOSdv/YqRjM=" + } + } + }, + "esprima": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.0.tgz", + "integrity": "sha512-oftTcaMu/EGrEIu904mWteKIv8vMuOgGYo7EhVJJN00R/EED9DCua/xxHRdYnKtcECzVg7xOWhflvJMnqcFZjw==" + }, + "estraverse": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.2.0.tgz", + "integrity": "sha1-De4/7TH81GlhjOc0IJn8GvoL2xM=" + }, + "esutils": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.2.tgz", + "integrity": "sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs=" + }, + "exec-sh": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/exec-sh/-/exec-sh-0.2.1.tgz", + "integrity": "sha512-aLt95pexaugVtQerpmE51+4QfWrNc304uez7jvj6fWnN8GeEHpttB8F36n8N7uVhUMbH/1enbxQ9HImZ4w/9qg==", + "requires": { + "merge": "1.2.0" + } + }, + "execa": { + "version": "0.7.0", + "resolved": "https://registry.npmjs.org/execa/-/execa-0.7.0.tgz", + "integrity": "sha1-lEvs00zEHuMqY6n68nrVpl/Fl3c=", + "requires": { + "cross-spawn": "5.1.0", + "get-stream": "3.0.0", + "is-stream": "1.1.0", + "npm-run-path": "2.0.2", + "p-finally": "1.0.0", + "signal-exit": "3.0.2", + "strip-eof": "1.0.0" + } + }, + "expand-brackets": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", + "integrity": "sha1-t3c14xXOMPa27/D4OwQVGiJEliI=", + "requires": { + "debug": "2.6.9", + "define-property": "0.2.5", + "extend-shallow": "2.0.1", + "posix-character-classes": "0.1.1", + "regex-not": "1.0.0", + "snapdragon": "0.8.1", + "to-regex": "3.0.1" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "requires": { + "is-descriptor": "0.1.6" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==" + } + } + }, + "expand-range": { + "version": "1.8.2", + "resolved": "https://registry.npmjs.org/expand-range/-/expand-range-1.8.2.tgz", + "integrity": "sha1-opnv/TNf4nIeuujiV+x5ZE/IUzc=", + "requires": { + "fill-range": "2.2.3" + }, + "dependencies": { + "fill-range": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-2.2.3.tgz", + "integrity": "sha1-ULd9/X5Gm8dJJHCWNpn+eoSFpyM=", + "requires": { + "is-number": "2.1.0", + "isobject": "2.1.0", + "randomatic": "1.1.7", + "repeat-element": "1.1.2", + "repeat-string": "1.6.1" + } + }, + "is-number": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-2.1.0.tgz", + "integrity": "sha1-Afy7s5NGOlSPL0ZszhbezknbkI8=", + "requires": { + "kind-of": "3.2.2" + } + }, + "isobject": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-2.1.0.tgz", + "integrity": "sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk=", + "requires": { + "isarray": "1.0.0" + } + }, + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "expect": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/expect/-/expect-22.0.3.tgz", + "integrity": "sha512-QapzeQkcA3jCx4pDnD07I4SPPxScKbey8TD/WwrnzmpHmL5q0dUtXfUt5OIFOjVBCg+C4zn4Y1zK9Rb9SIDL1g==", + "requires": { + "ansi-styles": "3.2.0", + "jest-diff": "22.0.3", + "jest-get-type": "22.0.3", + "jest-matcher-utils": "22.0.3", + "jest-message-util": "22.0.3", + "jest-regex-util": "22.0.3" + }, + "dependencies": { + "ansi-styles": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.0.tgz", + "integrity": "sha512-NnSOmMEYtVR2JVMIGTzynRkkaxtiq1xnFBcdQD/DnNCYPoEPsVJhM98BDyaoNOQIi7p4okdi3E27eN7GQbsUug==", + "requires": { + "color-convert": "1.9.1" + } + } + } + }, + "extend": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.1.tgz", + "integrity": "sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ=" + }, + "extend-shallow": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-2.0.1.tgz", + "integrity": "sha1-Ua99YUrZqfYQ6huvu5idaxxWiQ8=", + "requires": { + "is-extendable": "0.1.1" + } + }, + "extglob": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-2.0.3.tgz", + "integrity": "sha512-AyptZexgu7qppEPq59DtN/XJGZDrLcVxSHai+4hdgMMS9EpF4GBvygcWWApno8lL9qSjVpYt7Raao28qzJX1ww==", + "requires": { + "array-unique": "0.3.2", + "define-property": "1.0.0", + "expand-brackets": "2.1.4", + "extend-shallow": "2.0.1", + "fragment-cache": "0.2.1", + "regex-not": "1.0.0", + "snapdragon": "0.8.1", + "to-regex": "3.0.1" + } + }, + "extsprintf": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", + "integrity": "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU=" + }, + "fast-deep-equal": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-1.0.0.tgz", + "integrity": "sha1-liVqO8l1WV6zbYLpkp0GDYk0Of8=" + }, + "fast-glob": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-1.0.1.tgz", + "integrity": "sha512-C2VHbdBwSkaQDyavjQZDflZzmZKrsUK3fTdJtsOnED0L0vtHCw+NL0h8pRcydbpRHlNJLZ4/LbOfEdJKspK91A==", + "requires": { + "bash-glob": "1.0.2", + "glob-parent": "3.1.0", + "micromatch": "3.1.4", + "readdir-enhanced": "1.5.2" + } + }, + "fast-json-stable-stringify": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz", + "integrity": "sha1-1RQsDK7msRifh9OnYREGT4bIu/I=" + }, + "fast-levenshtein": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", + "integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=" + }, + "fb-watchman": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/fb-watchman/-/fb-watchman-2.0.0.tgz", + "integrity": "sha1-VOmr99+i8mzZsWNsWIwa/AXeXVg=", + "requires": { + "bser": "2.0.0" + } + }, + "filename-regex": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/filename-regex/-/filename-regex-2.0.1.tgz", + "integrity": "sha1-wcS5vuPglyXdsQa3XB4wH+LxiyY=" + }, + "fileset": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/fileset/-/fileset-2.0.3.tgz", + "integrity": "sha1-jnVIqW08wjJ+5eZ0FocjozO7oqA=", + "requires": { + "glob": "7.1.2", + "minimatch": "3.0.4" + } + }, + "fill-range": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", + "integrity": "sha1-1USBHUKPmOsGpj3EAtJAPDKMOPc=", + "requires": { + "extend-shallow": "2.0.1", + "is-number": "3.0.0", + "repeat-string": "1.6.1", + "to-regex-range": "2.1.1" + } + }, + "find-index": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/find-index/-/find-index-0.1.1.tgz", + "integrity": "sha1-Z101iyyjiS15Whq0cjL4tuLg3eQ=" + }, + "find-up": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz", + "integrity": "sha1-RdG35QbHF93UgndaK3eSCjwMV6c=", + "requires": { + "locate-path": "2.0.0" + } + }, + "for-in": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/for-in/-/for-in-1.0.2.tgz", + "integrity": "sha1-gQaNKVqBQuwKxybG4iAMMPttXoA=" + }, + "for-own": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/for-own/-/for-own-0.1.5.tgz", + "integrity": "sha1-UmXGgaTylNq78XyVCbZ2OqhFEM4=", + "requires": { + "for-in": "1.0.2" + } + }, + "foreach": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/foreach/-/foreach-2.0.5.tgz", + "integrity": "sha1-C+4AUBiusmDQo6865ljdATbsG5k=" + }, + "forever-agent": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", + "integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=" + }, + "form-data": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.1.tgz", + "integrity": "sha1-b7lPvXGIUwbXPRXMSX/kzE7NRL8=", + "requires": { + "asynckit": "0.4.0", + "combined-stream": "1.0.5", + "mime-types": "2.1.17" + } + }, + "formatio": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/formatio/-/formatio-1.2.0.tgz", + "integrity": "sha1-87IWfZBoxGmKjVH092CjmlTYGOs=", + "requires": { + "samsam": "1.3.0" + } + }, + "fragment-cache": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/fragment-cache/-/fragment-cache-0.2.1.tgz", + "integrity": "sha1-QpD60n8T6Jvn8zeZxrxaCr//DRk=", + "requires": { + "map-cache": "0.2.2" + } + }, + "fs-extra": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-4.0.3.tgz", + "integrity": "sha512-q6rbdDd1o2mAnQreO7YADIxf/Whx4AHBiRf6d+/cVT8h44ss+lHgxf1FemcqDnQt9X3ct4McHr+JMGlYSsK7Cg==", + "requires": { + "graceful-fs": "4.1.11", + "jsonfile": "4.0.0", + "universalify": "0.1.1" + } + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, + "get-caller-file": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-1.0.2.tgz", + "integrity": "sha1-9wLmMSfn4jHBYKgMFVSstw1QR+U=" + }, + "get-stream": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-3.0.0.tgz", + "integrity": "sha1-jpQ9E1jcN1VQVOy+LtsFqhdO3hQ=" + }, + "get-value": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/get-value/-/get-value-2.0.6.tgz", + "integrity": "sha1-3BXKHGcjh8p2vTesCjlbogQqLCg=" + }, + "getpass": { + "version": "0.1.7", + "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", + "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=", + "requires": { + "assert-plus": "1.0.0" + } + }, + "glob": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.2.tgz", + "integrity": "sha512-MJTUg1kjuLeQCJ+ccE4Vpa6kKVXkPYJ2mOCQyUuKLcLQsdrMCpBPUi8qVE6+YuaJkozeA9NusTAw3hLr8Xe5EQ==", + "requires": { + "fs.realpath": "1.0.0", + "inflight": "1.0.6", + "inherits": "2.0.3", + "minimatch": "3.0.4", + "once": "1.4.0", + "path-is-absolute": "1.0.1" + } + }, + "glob-base": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/glob-base/-/glob-base-0.3.0.tgz", + "integrity": "sha1-27Fk9iIbHAscz4Kuoyi0l98Oo8Q=", + "requires": { + "glob-parent": "2.0.0", + "is-glob": "2.0.1" + }, + "dependencies": { + "glob-parent": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-2.0.0.tgz", + "integrity": "sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg=", + "requires": { + "is-glob": "2.0.1" + } + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=" + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "requires": { + "is-extglob": "1.0.0" + } + } + } + }, + "glob-parent": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-3.1.0.tgz", + "integrity": "sha1-nmr2KZ2NO9K9QEMIMr0RPfkGxa4=", + "requires": { + "is-glob": "3.1.0", + "path-dirname": "1.0.2" + }, + "dependencies": { + "is-glob": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-3.1.0.tgz", + "integrity": "sha1-e6WuJCF4BKxwcHuWkiVnSGzD6Eo=", + "requires": { + "is-extglob": "2.1.1" + } + } + } + }, + "glob-to-regexp": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/glob-to-regexp/-/glob-to-regexp-0.3.0.tgz", + "integrity": "sha1-jFoUlNIGbFcMw7/kSWF1rMTVAqs=" + }, + "glob2base": { + "version": "0.0.12", + "resolved": "https://registry.npmjs.org/glob2base/-/glob2base-0.0.12.tgz", + "integrity": "sha1-nUGbPijxLoOjYhZKJ3BVkiycDVY=", + "requires": { + "find-index": "0.1.1" + } + }, + "globals": { + "version": "9.18.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-9.18.0.tgz", + "integrity": "sha512-S0nG3CLEQiY/ILxqtztTWH/3iRRdyBLw6KMDxnKMchrtbj2OFmehVh0WUCfW3DUrIgx/qFrJPICrq4Z4sTR9UQ==" + }, + "graceful-fs": { + "version": "4.1.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.11.tgz", + "integrity": "sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg=" + }, + "growly": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/growly/-/growly-1.3.0.tgz", + "integrity": "sha1-8QdIy+dq+WS3yWyTxrzCivEgwIE=" + }, + "handlebars": { + "version": "4.0.11", + "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.0.11.tgz", + "integrity": "sha1-Ywo13+ApS8KB7a5v/F0yn8eYLcw=", + "requires": { + "async": "1.5.2", + "optimist": "0.6.1", + "source-map": "0.4.4" + }, + "dependencies": { + "source-map": { + "version": "0.4.4", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.4.4.tgz", + "integrity": "sha1-66T12pwNyZneaAMti092FzZSA2s=", + "requires": { + "amdefine": "1.0.1" + } + } + } + }, + "har-schema": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz", + "integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=" + }, + "har-validator": { + "version": "5.0.3", + "resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.0.3.tgz", + "integrity": "sha1-ukAsJmGU8VlW7xXg/PJCmT9qff0=", + "requires": { + "ajv": "5.5.2", + "har-schema": "2.0.0" + } + }, + "has": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.1.tgz", + "integrity": "sha1-hGFzP1OLCDfJNh45qauelwTcLyg=", + "requires": { + "function-bind": "1.1.1" + } + }, + "has-ansi": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", + "integrity": "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=", + "requires": { + "ansi-regex": "2.1.1" + } + }, + "has-flag": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-2.0.0.tgz", + "integrity": "sha1-6CB68cx7MNRGzHC3NLXovhj4jVE=" + }, + "has-value": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-value/-/has-value-1.0.0.tgz", + "integrity": "sha1-GLKB2lhbHFxR3vJMkw7SmgvmsXc=", + "requires": { + "get-value": "2.0.6", + "has-values": "1.0.0", + "isobject": "3.0.1" + } + }, + "has-values": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-values/-/has-values-1.0.0.tgz", + "integrity": "sha1-lbC2P+whRmGab+V/51Yo1aOe/k8=", + "requires": { + "is-number": "3.0.0", + "kind-of": "4.0.0" + }, + "dependencies": { + "kind-of": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-4.0.0.tgz", + "integrity": "sha1-IIE989cSkosgc3hpGkUGb65y3Vc=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "hawk": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/hawk/-/hawk-6.0.2.tgz", + "integrity": "sha512-miowhl2+U7Qle4vdLqDdPt9m09K6yZhkLDTWGoUiUzrQCn+mHHSmfJgAyGaLRZbPmTqfFFjRV1QWCW0VWUJBbQ==", + "requires": { + "boom": "4.3.1", + "cryptiles": "3.1.2", + "hoek": "4.2.0", + "sntp": "2.1.0" + } + }, + "hoek": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/hoek/-/hoek-4.2.0.tgz", + "integrity": "sha512-v0XCLxICi9nPfYrS9RL8HbYnXi9obYAeLbSP00BmnZwCK9+Ih9WOjoZ8YoHCoav2csqn4FOz4Orldsy2dmDwmQ==" + }, + "home-or-tmp": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/home-or-tmp/-/home-or-tmp-2.0.0.tgz", + "integrity": "sha1-42w/LSyufXRqhX440Y1fMqeILbg=", + "requires": { + "os-homedir": "1.0.2", + "os-tmpdir": "1.0.2" + } + }, + "hosted-git-info": { + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.5.0.tgz", + "integrity": "sha512-pNgbURSuab90KbTqvRPsseaTxOJCZBD0a7t+haSN33piP9cCM4l0CqdzAif2hUqm716UovKB2ROmiabGAKVXyg==" + }, + "html-encoding-sniffer": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/html-encoding-sniffer/-/html-encoding-sniffer-1.0.2.tgz", + "integrity": "sha512-71lZziiDnsuabfdYiUeWdCVyKuqwWi23L8YeIgV9jSSZHCtb6wB1BKWooH7L3tn4/FuZJMVWyNaIDr4RGmaSYw==", + "requires": { + "whatwg-encoding": "1.0.3" + } + }, + "http-signature": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz", + "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=", + "requires": { + "assert-plus": "1.0.0", + "jsprim": "1.4.1", + "sshpk": "1.13.1" + } + }, + "iconv-lite": { + "version": "0.4.19", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.19.tgz", + "integrity": "sha512-oTZqweIP51xaGPI4uPa56/Pri/480R+mo7SeU+YETByQNhDG55ycFyNLIgta9vXhILrxXDmF7ZGhqZIcuN0gJQ==" + }, + "imurmurhash": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", + "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=" + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", + "requires": { + "once": "1.4.0", + "wrappy": "1.0.2" + } + }, + "inherits": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", + "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" + }, + "invariant": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.2.tgz", + "integrity": "sha1-nh9WrArNtr8wMwbzOL47IErmA2A=", + "requires": { + "loose-envify": "1.3.1" + } + }, + "invert-kv": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/invert-kv/-/invert-kv-1.0.0.tgz", + "integrity": "sha1-EEqOSqym09jNFXqO+L+rLXo//bY=" + }, + "is-accessor-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", + "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", + "requires": { + "kind-of": "6.0.2" + } + }, + "is-arrayish": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", + "integrity": "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0=" + }, + "is-binary-path": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-1.0.1.tgz", + "integrity": "sha1-dfFmQrSA8YenEcgUFh/TpKdlWJg=", + "requires": { + "binary-extensions": "1.11.0" + } + }, + "is-buffer": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", + "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==" + }, + "is-builtin-module": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-builtin-module/-/is-builtin-module-1.0.0.tgz", + "integrity": "sha1-VAVy0096wxGfj3bDDLwbHgN6/74=", + "requires": { + "builtin-modules": "1.1.1" + } + }, + "is-callable": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.1.3.tgz", + "integrity": "sha1-hut1OSgF3cM69xySoO7fdO52BLI=" + }, + "is-ci": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/is-ci/-/is-ci-1.0.10.tgz", + "integrity": "sha1-9zkzayYyNlBhqdSCcM1WrjNpMY4=", + "requires": { + "ci-info": "1.1.2" + } + }, + "is-data-descriptor": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", + "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", + "requires": { + "kind-of": "6.0.2" + } + }, + "is-date-object": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.1.tgz", + "integrity": "sha1-mqIOtq7rv/d/vTPnTKAbM1gdOhY=" + }, + "is-descriptor": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", + "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", + "requires": { + "is-accessor-descriptor": "1.0.0", + "is-data-descriptor": "1.0.0", + "kind-of": "6.0.2" + } + }, + "is-dotfile": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/is-dotfile/-/is-dotfile-1.0.3.tgz", + "integrity": "sha1-pqLzL/0t+wT1yiXs0Pa4PPeYoeE=" + }, + "is-equal-shallow": { + "version": "0.1.3", + "resolved": "https://registry.npmjs.org/is-equal-shallow/-/is-equal-shallow-0.1.3.tgz", + "integrity": "sha1-IjgJj8Ih3gvPpdnqxMRdY4qhxTQ=", + "requires": { + "is-primitive": "2.0.0" + } + }, + "is-extendable": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-0.1.1.tgz", + "integrity": "sha1-YrEQ4omkcUGOPsNqYX1HLjAd/Ik=" + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=" + }, + "is-finite": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.0.2.tgz", + "integrity": "sha1-zGZ3aVYCvlUO8R6LSqYwU0K20Ko=", + "requires": { + "number-is-nan": "1.0.1" + } + }, + "is-fullwidth-code-point": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", + "integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=", + "requires": { + "number-is-nan": "1.0.1" + } + }, + "is-glob": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.0.tgz", + "integrity": "sha1-lSHHaEXMJhCoUgPd8ICpWML/q8A=", + "requires": { + "is-extglob": "2.1.1" + } + }, + "is-number": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-3.0.0.tgz", + "integrity": "sha1-JP1iAaR4LPUFYcgQJ2r8fRLXEZU=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-odd": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-odd/-/is-odd-1.0.0.tgz", + "integrity": "sha1-O4qTLrAos3dcObsJ6RdnrM22kIg=", + "requires": { + "is-number": "3.0.0" + } + }, + "is-plain-object": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/is-plain-object/-/is-plain-object-2.0.4.tgz", + "integrity": "sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og==", + "requires": { + "isobject": "3.0.1" + } + }, + "is-posix-bracket": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/is-posix-bracket/-/is-posix-bracket-0.1.1.tgz", + "integrity": "sha1-MzTceXdDaOkvAW5vvAqI9c1ua8Q=" + }, + "is-primitive": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-primitive/-/is-primitive-2.0.0.tgz", + "integrity": "sha1-IHurkWOEmcB7Kt8kCkGochADRXU=" + }, + "is-regex": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.0.4.tgz", + "integrity": "sha1-VRdIm1RwkbCTDglWVM7SXul+lJE=", + "requires": { + "has": "1.0.1" + } + }, + "is-stream": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", + "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=" + }, + "is-symbol": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.1.tgz", + "integrity": "sha1-PMWfAAJRlLarLjjbrmaJJWtmBXI=" + }, + "is-typedarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", + "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=" + }, + "is-utf8": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/is-utf8/-/is-utf8-0.2.1.tgz", + "integrity": "sha1-Sw2hRCEE0bM2NA6AeX6GXPOffXI=" + }, + "is-windows": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-windows/-/is-windows-1.0.1.tgz", + "integrity": "sha1-MQ23D3QtJZoWo2kgK1GvhCMzENk=" + }, + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=" + }, + "isobject": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz", + "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" + }, + "isstream": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", + "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=" + }, + "istanbul-api": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/istanbul-api/-/istanbul-api-1.2.1.tgz", + "integrity": "sha512-oFCwXvd65amgaPCzqrR+a2XjanS1MvpXN6l/MlMUTv6uiA1NOgGX+I0uyq8Lg3GDxsxPsaP1049krz3hIJ5+KA==", + "requires": { + "async": "2.6.0", + "fileset": "2.0.3", + "istanbul-lib-coverage": "1.1.1", + "istanbul-lib-hook": "1.1.0", + "istanbul-lib-instrument": "1.9.1", + "istanbul-lib-report": "1.1.2", + "istanbul-lib-source-maps": "1.2.2", + "istanbul-reports": "1.1.3", + "js-yaml": "3.10.0", + "mkdirp": "0.5.1", + "once": "1.4.0" + }, + "dependencies": { + "async": { + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/async/-/async-2.6.0.tgz", + "integrity": "sha512-xAfGg1/NTLBBKlHFmnd7PlmUW9KhVQIUuSrYem9xzFUZy13ScvtyGGejaae9iAVRiRq9+Cx7DPFaAAhCpyxyPw==", + "requires": { + "lodash": "4.17.4" + } + } + } + }, + "istanbul-lib-coverage": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-1.1.1.tgz", + "integrity": "sha512-0+1vDkmzxqJIn5rcoEqapSB4DmPxE31EtI2dF2aCkV5esN9EWHxZ0dwgDClivMXJqE7zaYQxq30hj5L0nlTN5Q==" + }, + "istanbul-lib-hook": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/istanbul-lib-hook/-/istanbul-lib-hook-1.1.0.tgz", + "integrity": "sha512-U3qEgwVDUerZ0bt8cfl3dSP3S6opBoOtk3ROO5f2EfBr/SRiD9FQqzwaZBqFORu8W7O0EXpai+k7kxHK13beRg==", + "requires": { + "append-transform": "0.4.0" + } + }, + "istanbul-lib-instrument": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/istanbul-lib-instrument/-/istanbul-lib-instrument-1.9.1.tgz", + "integrity": "sha512-RQmXeQ7sphar7k7O1wTNzVczF9igKpaeGQAG9qR2L+BS4DCJNTI9nytRmIVYevwO0bbq+2CXvJmYDuz0gMrywA==", + "requires": { + "babel-generator": "6.26.0", + "babel-template": "6.26.0", + "babel-traverse": "6.26.0", + "babel-types": "6.26.0", + "babylon": "6.18.0", + "istanbul-lib-coverage": "1.1.1", + "semver": "5.4.1" + } + }, + "istanbul-lib-report": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/istanbul-lib-report/-/istanbul-lib-report-1.1.2.tgz", + "integrity": "sha512-UTv4VGx+HZivJQwAo1wnRwe1KTvFpfi/NYwN7DcsrdzMXwpRT/Yb6r4SBPoHWj4VuQPakR32g4PUUeyKkdDkBA==", + "requires": { + "istanbul-lib-coverage": "1.1.1", + "mkdirp": "0.5.1", + "path-parse": "1.0.5", + "supports-color": "3.2.3" + }, + "dependencies": { + "has-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-1.0.0.tgz", + "integrity": "sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo=" + }, + "supports-color": { + "version": "3.2.3", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-3.2.3.tgz", + "integrity": "sha1-ZawFBLOVQXHYpklGsq48u4pfVPY=", + "requires": { + "has-flag": "1.0.0" + } + } + } + }, + "istanbul-lib-source-maps": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/istanbul-lib-source-maps/-/istanbul-lib-source-maps-1.2.2.tgz", + "integrity": "sha512-8BfdqSfEdtip7/wo1RnrvLpHVEd8zMZEDmOFEnpC6dg0vXflHt9nvoAyQUzig2uMSXfF2OBEYBV3CVjIL9JvaQ==", + "requires": { + "debug": "3.1.0", + "istanbul-lib-coverage": "1.1.1", + "mkdirp": "0.5.1", + "rimraf": "2.6.2", + "source-map": "0.5.7" + }, + "dependencies": { + "debug": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.1.0.tgz", + "integrity": "sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g==", + "requires": { + "ms": "2.0.0" + } + } + } + }, + "istanbul-reports": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/istanbul-reports/-/istanbul-reports-1.1.3.tgz", + "integrity": "sha512-ZEelkHh8hrZNI5xDaKwPMFwDsUf5wIEI2bXAFGp1e6deR2mnEKBPhLJEgr4ZBt8Gi6Mj38E/C8kcy9XLggVO2Q==", + "requires": { + "handlebars": "4.0.11" + } + }, + "jest": { + "version": "22.0.4", + "resolved": "https://registry.npmjs.org/jest/-/jest-22.0.4.tgz", + "integrity": "sha512-S0tmgK5psULvt/11QzgAZWGpY5y5TkMRzd3T21Q13JzTx37Vx6F0Nw022c9Kc/IbEy+AHkKkGFVO5QafE8MrDg==", + "requires": { + "jest-cli": "22.0.4" + }, + "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" + }, + "arr-diff": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-2.0.0.tgz", + "integrity": "sha1-jzuCf5Vai9ZpaX5KQlasPOrjVs8=", + "requires": { + "arr-flatten": "1.1.0" + } + }, + "array-unique": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.2.1.tgz", + "integrity": "sha1-odl8yvy8JiXMcPrc6zalDFiwGlM=" + }, + "braces": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/braces/-/braces-1.8.5.tgz", + "integrity": "sha1-uneWLhLf+WnWt2cR6RS3N4V79qc=", + "requires": { + "expand-range": "1.8.2", + "preserve": "0.2.0", + "repeat-element": "1.1.2" + } + }, + "expand-brackets": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-0.1.5.tgz", + "integrity": "sha1-3wcoTjQqgHzXM6xa9yQR5YHRF3s=", + "requires": { + "is-posix-bracket": "0.1.1" + } + }, + "extglob": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-0.3.2.tgz", + "integrity": "sha1-Lhj/PS9JqydlzskCPwEdqo2DSaE=", + "requires": { + "is-extglob": "1.0.0" + } + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=" + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "requires": { + "is-extglob": "1.0.0" + } + }, + "jest-cli": { + "version": "22.0.4", + "resolved": "https://registry.npmjs.org/jest-cli/-/jest-cli-22.0.4.tgz", + "integrity": "sha512-f1lZRM13IwIINzjE3RebXQKtQLiKncpSrbJZ/aTZJXmzEWGdgSayW4ESyhU+xK3uGiJEUSzbHjwPY6nGJ8VbUA==", + "requires": { + "ansi-escapes": "3.0.0", + "chalk": "2.3.0", + "glob": "7.1.2", + "graceful-fs": "4.1.11", + "is-ci": "1.0.10", + "istanbul-api": "1.2.1", + "istanbul-lib-coverage": "1.1.1", + "istanbul-lib-instrument": "1.9.1", + "istanbul-lib-source-maps": "1.2.2", + "jest-changed-files": "22.0.3", + "jest-config": "22.0.4", + "jest-environment-jsdom": "22.0.4", + "jest-get-type": "22.0.3", + "jest-haste-map": "22.0.3", + "jest-message-util": "22.0.3", + "jest-regex-util": "22.0.3", + "jest-resolve-dependencies": "22.0.3", + "jest-runner": "22.0.4", + "jest-runtime": "22.0.4", + "jest-snapshot": "22.0.3", + "jest-util": "22.0.4", + "jest-worker": "22.0.3", + "micromatch": "2.3.11", + "node-notifier": "5.1.2", + "realpath-native": "1.0.0", + "rimraf": "2.6.2", + "slash": "1.0.0", + "string-length": "2.0.0", + "strip-ansi": "4.0.0", + "which": "1.3.0", + "yargs": "10.0.3" + } + }, + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + }, + "micromatch": { + "version": "2.3.11", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-2.3.11.tgz", + "integrity": "sha1-hmd8l9FyCzY0MdBNDRUpO9OMFWU=", + "requires": { + "arr-diff": "2.0.0", + "array-unique": "0.2.1", + "braces": "1.8.5", + "expand-brackets": "0.1.5", + "extglob": "0.3.2", + "filename-regex": "2.0.1", + "is-extglob": "1.0.0", + "is-glob": "2.0.1", + "kind-of": "3.2.2", + "normalize-path": "2.1.1", + "object.omit": "2.0.1", + "parse-glob": "3.0.4", + "regex-cache": "0.4.4" + } + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "requires": { + "ansi-regex": "3.0.0" + } + } + } + }, + "jest-changed-files": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-changed-files/-/jest-changed-files-22.0.3.tgz", + "integrity": "sha512-CG7eNJNO9x1O/3J4Uhe2QXra1MnC9+KS1f2NeOg+7iQ+8dDCgxCtpusmKfu44TnEyKwkIDhDr6htPfPaI+Fwbw==", + "requires": { + "throat": "4.1.0" + } + }, + "jest-config": { + "version": "22.0.4", + "resolved": "https://registry.npmjs.org/jest-config/-/jest-config-22.0.4.tgz", + "integrity": "sha512-NcBeixqHjHDZO9+pUj+365LQV2s65d2f0/IrwlUyv0xaJovRNc6eDvoJ/r2UUlHnqjP3Go+R0ECUsXPXjk4SHw==", + "requires": { + "chalk": "2.3.0", + "glob": "7.1.2", + "jest-environment-jsdom": "22.0.4", + "jest-environment-node": "22.0.4", + "jest-get-type": "22.0.3", + "jest-jasmine2": "22.0.4", + "jest-regex-util": "22.0.3", + "jest-resolve": "22.0.4", + "jest-util": "22.0.4", + "jest-validate": "22.0.3", + "pretty-format": "22.0.3" + } + }, + "jest-diff": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-diff/-/jest-diff-22.0.3.tgz", + "integrity": "sha512-Y7xN9Lc/NgFvR14lvjrJXB6x2x1LLe5NnMyzLvilBSSOyjy9uAVnR2Bt1YgzdfRrfaxsx7xFUVcqXLUnPkrJcA==", + "requires": { + "chalk": "2.3.0", + "diff": "3.4.0", + "jest-get-type": "22.0.3", + "pretty-format": "22.0.3" + } + }, + "jest-docblock": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-docblock/-/jest-docblock-22.0.3.tgz", + "integrity": "sha512-LhviP2rqIg2IzS6m97W7T032oMrT699Tr6Njjhhl4FCLj+75BUy9CsSmGgfoVEql1uc+myBkssvcbn7T9xDR+A==", + "requires": { + "detect-newline": "2.1.0" + } + }, + "jest-environment-jsdom": { + "version": "22.0.4", + "resolved": "https://registry.npmjs.org/jest-environment-jsdom/-/jest-environment-jsdom-22.0.4.tgz", + "integrity": "sha512-vnjefLZlsNsmnjKcaXkx2IxTBNG40vfRVOdMfcfkPkq85JxFB7wzNtjLx+RIfiNpIZd04C1PXbF0aJIenY85Ng==", + "requires": { + "jest-mock": "22.0.3", + "jest-util": "22.0.4", + "jsdom": "11.5.1" + } + }, + "jest-environment-node": { + "version": "22.0.4", + "resolved": "https://registry.npmjs.org/jest-environment-node/-/jest-environment-node-22.0.4.tgz", + "integrity": "sha512-9vjNKb86UivvKCZCudMNixQgdMnOG7ql6iVYnaiK0CmvZ0WQD+mlM10NvgiWpRv4HstcnRL1pY/GSIHXAD6qXw==", + "requires": { + "jest-mock": "22.0.3", + "jest-util": "22.0.4" + } + }, + "jest-get-type": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-get-type/-/jest-get-type-22.0.3.tgz", + "integrity": "sha512-TaJnc/lnJQ3jwry+NUWkqaJmKrM/Ut3XdK89HfiqdI3DMRLd6Zb4wyKjwuNP37MEQqlNg0YWH4sbBR8D4exjCA==" + }, + "jest-haste-map": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-haste-map/-/jest-haste-map-22.0.3.tgz", + "integrity": "sha512-VosIMOFQFu1rTF+MvOWVuv2KVmZ9eTkRgfwW2yUAs6/AhwmIfXRl/tih+fIOYcHzU4Auu1G8Fvl2kkF5g0k6/A==", + "requires": { + "fb-watchman": "2.0.0", + "graceful-fs": "4.1.11", + "jest-docblock": "22.0.3", + "jest-worker": "22.0.3", + "micromatch": "2.3.11", + "sane": "2.2.0" + }, + "dependencies": { + "arr-diff": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-2.0.0.tgz", + "integrity": "sha1-jzuCf5Vai9ZpaX5KQlasPOrjVs8=", + "requires": { + "arr-flatten": "1.1.0" + } + }, + "array-unique": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.2.1.tgz", + "integrity": "sha1-odl8yvy8JiXMcPrc6zalDFiwGlM=" + }, + "braces": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/braces/-/braces-1.8.5.tgz", + "integrity": "sha1-uneWLhLf+WnWt2cR6RS3N4V79qc=", + "requires": { + "expand-range": "1.8.2", + "preserve": "0.2.0", + "repeat-element": "1.1.2" + } + }, + "expand-brackets": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-0.1.5.tgz", + "integrity": "sha1-3wcoTjQqgHzXM6xa9yQR5YHRF3s=", + "requires": { + "is-posix-bracket": "0.1.1" + } + }, + "extglob": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-0.3.2.tgz", + "integrity": "sha1-Lhj/PS9JqydlzskCPwEdqo2DSaE=", + "requires": { + "is-extglob": "1.0.0" + } + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=" + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "requires": { + "is-extglob": "1.0.0" + } + }, + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + }, + "micromatch": { + "version": "2.3.11", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-2.3.11.tgz", + "integrity": "sha1-hmd8l9FyCzY0MdBNDRUpO9OMFWU=", + "requires": { + "arr-diff": "2.0.0", + "array-unique": "0.2.1", + "braces": "1.8.5", + "expand-brackets": "0.1.5", + "extglob": "0.3.2", + "filename-regex": "2.0.1", + "is-extglob": "1.0.0", + "is-glob": "2.0.1", + "kind-of": "3.2.2", + "normalize-path": "2.1.1", + "object.omit": "2.0.1", + "parse-glob": "3.0.4", + "regex-cache": "0.4.4" + } + } + } + }, + "jest-jasmine2": { + "version": "22.0.4", + "resolved": "https://registry.npmjs.org/jest-jasmine2/-/jest-jasmine2-22.0.4.tgz", + "integrity": "sha512-pn1XPHUkffHK6oNY1Dfl/+Rg0UuTdlg3aGDnjyK6dZzGEBeiH1uKuSgZEjy3Lj461l3atpzsQyw7ilXPyjFnUw==", + "requires": { + "callsites": "2.0.0", + "chalk": "2.3.0", + "expect": "22.0.3", + "graceful-fs": "4.1.11", + "jest-diff": "22.0.3", + "jest-matcher-utils": "22.0.3", + "jest-message-util": "22.0.3", + "jest-snapshot": "22.0.3", + "source-map-support": "0.5.0" + } + }, + "jest-leak-detector": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-leak-detector/-/jest-leak-detector-22.0.3.tgz", + "integrity": "sha512-xyVdAmcG8M3jWtVeadDUU6MAHLBrjkP4clz2UtTZ1gpe5bRLk27VjQOpzTwK20MkV/6iZQhSuRVuzHS5kD0HpA==", + "requires": { + "pretty-format": "22.0.3" + } + }, + "jest-matcher-utils": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-matcher-utils/-/jest-matcher-utils-22.0.3.tgz", + "integrity": "sha512-FJbKpCR3K7YYE/Pnvy5OrLFgPEswpYWIfVtdwT2NC6pBARbYGX39KF3bTxS9yg2mv0YL2zHe3UbwzFsi9nFpVA==", + "requires": { + "chalk": "2.3.0", + "jest-get-type": "22.0.3", + "pretty-format": "22.0.3" + } + }, + "jest-message-util": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-message-util/-/jest-message-util-22.0.3.tgz", + "integrity": "sha512-AVBdCx7Oj5wBpMOH089lx7Zgwpdz9HbReA82HuVAlIT4kEQRvCy6Sl9yVWDGJwHTgB/OYQGkgmbv/P/K8TkWNw==", + "requires": { + "@babel/code-frame": "7.0.0-beta.36", + "chalk": "2.3.0", + "micromatch": "2.3.11", + "slash": "1.0.0", + "stack-utils": "1.0.1" + }, + "dependencies": { + "arr-diff": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-2.0.0.tgz", + "integrity": "sha1-jzuCf5Vai9ZpaX5KQlasPOrjVs8=", + "requires": { + "arr-flatten": "1.1.0" + } + }, + "array-unique": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.2.1.tgz", + "integrity": "sha1-odl8yvy8JiXMcPrc6zalDFiwGlM=" + }, + "braces": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/braces/-/braces-1.8.5.tgz", + "integrity": "sha1-uneWLhLf+WnWt2cR6RS3N4V79qc=", + "requires": { + "expand-range": "1.8.2", + "preserve": "0.2.0", + "repeat-element": "1.1.2" + } + }, + "expand-brackets": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-0.1.5.tgz", + "integrity": "sha1-3wcoTjQqgHzXM6xa9yQR5YHRF3s=", + "requires": { + "is-posix-bracket": "0.1.1" + } + }, + "extglob": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-0.3.2.tgz", + "integrity": "sha1-Lhj/PS9JqydlzskCPwEdqo2DSaE=", + "requires": { + "is-extglob": "1.0.0" + } + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=" + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "requires": { + "is-extglob": "1.0.0" + } + }, + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + }, + "micromatch": { + "version": "2.3.11", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-2.3.11.tgz", + "integrity": "sha1-hmd8l9FyCzY0MdBNDRUpO9OMFWU=", + "requires": { + "arr-diff": "2.0.0", + "array-unique": "0.2.1", + "braces": "1.8.5", + "expand-brackets": "0.1.5", + "extglob": "0.3.2", + "filename-regex": "2.0.1", + "is-extglob": "1.0.0", + "is-glob": "2.0.1", + "kind-of": "3.2.2", + "normalize-path": "2.1.1", + "object.omit": "2.0.1", + "parse-glob": "3.0.4", + "regex-cache": "0.4.4" + } + } + } + }, + "jest-mock": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-mock/-/jest-mock-22.0.3.tgz", + "integrity": "sha512-donODXcDG03EAEavc9xfJ7fBF/LNVjoZYkmj9DLrQ1B9YcT6wh8Xx7IYg25b8V/8F/eXPMAE0KK5q6Fqe6yAeg==" + }, + "jest-regex-util": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-regex-util/-/jest-regex-util-22.0.3.tgz", + "integrity": "sha512-mplC9chiAotES3ClzNhy0SJcfHB2DivooKJZW+2hDdvP8LLB+OUI+D6bJd7sncbKUsyFcmblEvpm/zz/hef7HA==" + }, + "jest-resolve": { + "version": "22.0.4", + "resolved": "https://registry.npmjs.org/jest-resolve/-/jest-resolve-22.0.4.tgz", + "integrity": "sha512-yoxHsX4MTT2Ra/dFia9VCunzsA/4jMBENMmLjREIUkCIP1edk/PZUOGVVf680Gw04CtmT5stETylcbmbL7hJBw==", + "requires": { + "browser-resolve": "1.11.2", + "chalk": "2.3.0" + } + }, + "jest-resolve-dependencies": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-resolve-dependencies/-/jest-resolve-dependencies-22.0.3.tgz", + "integrity": "sha512-u9MUNJIa9GJ0YFhvM0+Scr4tyX84nC42d3w18Cly1doY7pTT+9momm+TncpuDlFyB2aNmS8SfdEbiLr1e6tBwg==", + "requires": { + "jest-regex-util": "22.0.3" + } + }, + "jest-runner": { + "version": "22.0.4", + "resolved": "https://registry.npmjs.org/jest-runner/-/jest-runner-22.0.4.tgz", + "integrity": "sha512-srBkbqmiSB+jzSaG652fmi3kS6rV6wS/4fOG8dxxBg3dCqNQcM2/L3TI3ZK0SwIAcdGJh5Gybs8aDboT8K9Cdw==", + "requires": { + "jest-config": "22.0.4", + "jest-docblock": "22.0.3", + "jest-haste-map": "22.0.3", + "jest-jasmine2": "22.0.4", + "jest-leak-detector": "22.0.3", + "jest-message-util": "22.0.3", + "jest-runtime": "22.0.4", + "jest-util": "22.0.4", + "jest-worker": "22.0.3", + "throat": "4.1.0" + } + }, + "jest-runtime": { + "version": "22.0.4", + "resolved": "https://registry.npmjs.org/jest-runtime/-/jest-runtime-22.0.4.tgz", + "integrity": "sha512-+7uEwf/4f8k1E/eViyGK6/M5yA4O3f6TdWViuqF9MV7vXwG2OVJu8YEZa5239nEnHJiwinXp4eZXX+HB4pQRPg==", + "requires": { + "babel-core": "6.26.0", + "babel-jest": "22.0.4", + "babel-plugin-istanbul": "4.1.5", + "chalk": "2.3.0", + "convert-source-map": "1.5.1", + "graceful-fs": "4.1.11", + "jest-config": "22.0.4", + "jest-haste-map": "22.0.3", + "jest-regex-util": "22.0.3", + "jest-resolve": "22.0.4", + "jest-util": "22.0.4", + "json-stable-stringify": "1.0.1", + "micromatch": "2.3.11", + "realpath-native": "1.0.0", + "slash": "1.0.0", + "strip-bom": "3.0.0", + "write-file-atomic": "2.3.0", + "yargs": "10.0.3" + }, + "dependencies": { + "arr-diff": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-2.0.0.tgz", + "integrity": "sha1-jzuCf5Vai9ZpaX5KQlasPOrjVs8=", + "requires": { + "arr-flatten": "1.1.0" + } + }, + "array-unique": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.2.1.tgz", + "integrity": "sha1-odl8yvy8JiXMcPrc6zalDFiwGlM=" + }, + "braces": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/braces/-/braces-1.8.5.tgz", + "integrity": "sha1-uneWLhLf+WnWt2cR6RS3N4V79qc=", + "requires": { + "expand-range": "1.8.2", + "preserve": "0.2.0", + "repeat-element": "1.1.2" + } + }, + "expand-brackets": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-0.1.5.tgz", + "integrity": "sha1-3wcoTjQqgHzXM6xa9yQR5YHRF3s=", + "requires": { + "is-posix-bracket": "0.1.1" + } + }, + "extglob": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-0.3.2.tgz", + "integrity": "sha1-Lhj/PS9JqydlzskCPwEdqo2DSaE=", + "requires": { + "is-extglob": "1.0.0" + } + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=" + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "requires": { + "is-extglob": "1.0.0" + } + }, + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + }, + "micromatch": { + "version": "2.3.11", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-2.3.11.tgz", + "integrity": "sha1-hmd8l9FyCzY0MdBNDRUpO9OMFWU=", + "requires": { + "arr-diff": "2.0.0", + "array-unique": "0.2.1", + "braces": "1.8.5", + "expand-brackets": "0.1.5", + "extglob": "0.3.2", + "filename-regex": "2.0.1", + "is-extglob": "1.0.0", + "is-glob": "2.0.1", + "kind-of": "3.2.2", + "normalize-path": "2.1.1", + "object.omit": "2.0.1", + "parse-glob": "3.0.4", + "regex-cache": "0.4.4" + } + }, + "strip-bom": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", + "integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=" + } + } + }, + "jest-snapshot": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-snapshot/-/jest-snapshot-22.0.3.tgz", + "integrity": "sha512-e/a/EvMsY5XROWy4QWX6PvYziuJ8ttD6+QcnbogODWtx2LGhvVQOb7pmqGTo0tL/p0vzFetZA9GlZSh/EfMepg==", + "requires": { + "chalk": "2.3.0", + "jest-diff": "22.0.3", + "jest-matcher-utils": "22.0.3", + "mkdirp": "0.5.1", + "natural-compare": "1.4.0", + "pretty-format": "22.0.3" + } + }, + "jest-util": { + "version": "22.0.4", + "resolved": "https://registry.npmjs.org/jest-util/-/jest-util-22.0.4.tgz", + "integrity": "sha512-gNNPtcCFkVh7daKIl3/06eoQ90QXGXCyDOfyZ3IEyTWmHBdX3GvklcOtyGcdOvrYEubaZTfMcMKmEeo/6sRTog==", + "requires": { + "callsites": "2.0.0", + "chalk": "2.3.0", + "graceful-fs": "4.1.11", + "is-ci": "1.0.10", + "jest-message-util": "22.0.3", + "jest-validate": "22.0.3", + "mkdirp": "0.5.1" + } + }, + "jest-validate": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-validate/-/jest-validate-22.0.3.tgz", + "integrity": "sha512-GmlLmPCtrSQ3iB4A1uxcfjawaaQnwESCDcUg5tMxJKeBbmPdcWPAb6EWzvANxULPUV7hfPKLwg4xIPpi7cx1/g==", + "requires": { + "chalk": "2.3.0", + "jest-get-type": "22.0.3", + "leven": "2.1.0", + "pretty-format": "22.0.3" + } + }, + "jest-worker": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/jest-worker/-/jest-worker-22.0.3.tgz", + "integrity": "sha512-fPdCTnogFQiR0CP6whEsIly2RfcHxvalqyLjhui6qa1SnOmHiX7L8k4Umo8CBIp5ndWY0+ej1o7OTE5MlzPabg==", + "requires": { + "merge-stream": "1.0.1" + } + }, + "js-tokens": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-3.0.2.tgz", + "integrity": "sha1-mGbfOVECEw449/mWvOtlRDIJwls=" + }, + "js-yaml": { + "version": "3.10.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.10.0.tgz", + "integrity": "sha512-O2v52ffjLa9VeM43J4XocZE//WT9N0IiwDa3KSHH7Tu8CtH+1qM8SIZvnsTh6v+4yFy5KUY3BHUVwjpfAWsjIA==", + "requires": { + "argparse": "1.0.9", + "esprima": "4.0.0" + } + }, + "jsdom": { + "version": "11.5.1", + "resolved": "https://registry.npmjs.org/jsdom/-/jsdom-11.5.1.tgz", + "integrity": "sha512-89ztIZ03aYK9f1uUrLXLsZndRge/JnZjzjpaN+lrse3coqz+8PR/dX4WLHpbF5fIKTXhDjFODOJw2328lPJ90g==", + "requires": { + "abab": "1.0.4", + "acorn": "5.3.0", + "acorn-globals": "4.1.0", + "array-equal": "1.0.0", + "browser-process-hrtime": "0.1.2", + "content-type-parser": "1.0.2", + "cssom": "0.3.2", + "cssstyle": "0.2.37", + "domexception": "1.0.0", + "escodegen": "1.9.0", + "html-encoding-sniffer": "1.0.2", + "left-pad": "1.2.0", + "nwmatcher": "1.4.3", + "parse5": "3.0.3", + "pn": "1.0.0", + "request": "2.83.0", + "request-promise-native": "1.0.5", + "sax": "1.2.4", + "symbol-tree": "3.2.2", + "tough-cookie": "2.3.3", + "webidl-conversions": "4.0.2", + "whatwg-encoding": "1.0.3", + "whatwg-url": "6.4.0", + "xml-name-validator": "2.0.1" + } + }, + "jsesc": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-1.3.0.tgz", + "integrity": "sha1-RsP+yMGJKxKwgz25vHYiF226s0s=" + }, + "json-parse-better-errors": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/json-parse-better-errors/-/json-parse-better-errors-1.0.1.tgz", + "integrity": "sha512-xyQpxeWWMKyJps9CuGJYeng6ssI5bpqS9ltQpdVQ90t4ql6NdnxFKh95JcRt2cun/DjMVNrdjniLPuMA69xmCw==" + }, + "json-schema": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz", + "integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=" + }, + "json-schema-traverse": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.3.1.tgz", + "integrity": "sha1-NJptRMU6Ud6JtAgFxdXlm0F9M0A=" + }, + "json-stable-stringify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/json-stable-stringify/-/json-stable-stringify-1.0.1.tgz", + "integrity": "sha1-mnWdOcXy/1A/1TAGRu1EX4jE+a8=", + "requires": { + "jsonify": "0.0.0" + } + }, + "json-stringify-safe": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", + "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=" + }, + "json5": { + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/json5/-/json5-0.5.1.tgz", + "integrity": "sha1-Hq3nrMASA0rYTiOWdn6tn6VJWCE=" + }, + "jsonfile": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz", + "integrity": "sha1-h3Gq4HmbZAdrdmQPygWPnBDjPss=", + "requires": { + "graceful-fs": "4.1.11" + } + }, + "jsonify": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/jsonify/-/jsonify-0.0.0.tgz", + "integrity": "sha1-LHS27kHZPKUbe1qu6PUDYx0lKnM=" + }, + "jsprim": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz", + "integrity": "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=", + "requires": { + "assert-plus": "1.0.0", + "extsprintf": "1.3.0", + "json-schema": "0.2.3", + "verror": "1.10.0" + } + }, + "just-extend": { + "version": "1.1.27", + "resolved": "https://registry.npmjs.org/just-extend/-/just-extend-1.1.27.tgz", + "integrity": "sha512-mJVp13Ix6gFo3SBAy9U/kL+oeZqzlYYYLQBwXVBlVzIsZwBqGREnOro24oC/8s8aox+rJhtZ2DiQof++IrkA+g==" + }, + "kind-of": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", + "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + }, + "lazy-cache": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/lazy-cache/-/lazy-cache-2.0.2.tgz", + "integrity": "sha1-uRkKT5EzVGlIQIWfio9whNiCImQ=", + "requires": { + "set-getter": "0.1.0" + } + }, + "lcid": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/lcid/-/lcid-1.0.0.tgz", + "integrity": "sha1-MIrMr6C8SDo4Z7S28rlQYlHRuDU=", + "requires": { + "invert-kv": "1.0.0" + } + }, + "left-pad": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/left-pad/-/left-pad-1.2.0.tgz", + "integrity": "sha1-0wpzxrggHY99jnlWupYWCHpo4O4=" + }, + "leven": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/leven/-/leven-2.1.0.tgz", + "integrity": "sha1-wuep93IJTe6dNCAq6KzORoeHVYA=" + }, + "levn": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", + "integrity": "sha1-OwmSTt+fCDwEkP3UwLxEIeBHZO4=", + "requires": { + "prelude-ls": "1.1.2", + "type-check": "0.3.2" + } + }, + "load-json-file": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz", + "integrity": "sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA=", + "requires": { + "graceful-fs": "4.1.11", + "parse-json": "2.2.0", + "pify": "2.3.0", + "pinkie-promise": "2.0.1", + "strip-bom": "2.0.0" + } + }, + "locate-path": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz", + "integrity": "sha1-K1aLJl7slExtnA3pw9u7ygNUzY4=", + "requires": { + "p-locate": "2.0.0", + "path-exists": "3.0.0" + } + }, + "lodash": { + "version": "4.17.4", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.4.tgz", + "integrity": "sha1-eCA6TRwyiuHYbcpkYONptX9AVa4=" + }, + "lodash.get": { + "version": "4.4.2", + "resolved": "https://registry.npmjs.org/lodash.get/-/lodash.get-4.4.2.tgz", + "integrity": "sha1-LRd/ZS+jHpObRDjVNBSZ36OCXpk=" + }, + "lodash.sortby": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/lodash.sortby/-/lodash.sortby-4.7.0.tgz", + "integrity": "sha1-7dFMgk4sycHgsKG0K7UhBRakJDg=" + }, + "lolex": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/lolex/-/lolex-2.3.1.tgz", + "integrity": "sha512-mQuW55GhduF3ppo+ZRUTz1PRjEh1hS5BbqU7d8D0ez2OKxHDod7StPPeAVKisZR5aLkHZjdGWSL42LSONUJsZw==" + }, + "loose-envify": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.3.1.tgz", + "integrity": "sha1-0aitM/qc4OcT1l/dCsi3SNR4yEg=", + "requires": { + "js-tokens": "3.0.2" + } + }, + "lru-cache": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.1.tgz", + "integrity": "sha512-q4spe4KTfsAS1SUHLO0wz8Qiyf1+vMIAgpRYioFYDMNqKfHQbg+AVDH3i4fvpl71/P1L0dBl+fQi+P37UYf0ew==", + "requires": { + "pseudomap": "1.0.2", + "yallist": "2.1.2" + } + }, + "makeerror": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/makeerror/-/makeerror-1.0.11.tgz", + "integrity": "sha1-4BpckQnyr3lmDk6LlYd5AYT1qWw=", + "requires": { + "tmpl": "1.0.4" + } + }, + "map-cache": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/map-cache/-/map-cache-0.2.2.tgz", + "integrity": "sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8=" + }, + "map-visit": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/map-visit/-/map-visit-1.0.0.tgz", + "integrity": "sha1-7Nyo8TFE5mDxtb1B8S80edmN+48=", + "requires": { + "object-visit": "1.0.1" + } + }, + "mem": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/mem/-/mem-1.1.0.tgz", + "integrity": "sha1-Xt1StIXKHZAP5kiVUFOZoN+kX3Y=", + "requires": { + "mimic-fn": "1.1.0" + } + }, + "merge": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/merge/-/merge-1.2.0.tgz", + "integrity": "sha1-dTHjnUlJwoGma4xabgJl6LBYlNo=" + }, + "merge-stream": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/merge-stream/-/merge-stream-1.0.1.tgz", + "integrity": "sha1-QEEgLVCKNCugAXQAjfDCUbjBNeE=", + "requires": { + "readable-stream": "2.3.3" + } + }, + "micromatch": { + "version": "3.1.4", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-3.1.4.tgz", + "integrity": "sha512-kFRtviKYoAJT+t7HggMl0tBFGNAKLw/S7N+CO9qfEQyisob1Oy4pao+geRbkyeEd+V9aOkvZ4mhuyPvI/q9Sfg==", + "requires": { + "arr-diff": "4.0.0", + "array-unique": "0.3.2", + "braces": "2.3.0", + "define-property": "1.0.0", + "extend-shallow": "2.0.1", + "extglob": "2.0.3", + "fragment-cache": "0.2.1", + "kind-of": "6.0.2", + "nanomatch": "1.2.6", + "object.pick": "1.3.0", + "regex-not": "1.0.0", + "snapdragon": "0.8.1", + "to-regex": "3.0.1" + } + }, + "mime-db": { + "version": "1.30.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.30.0.tgz", + "integrity": "sha1-dMZD2i3Z1qRTmZY0ZbJtXKfXHwE=" + }, + "mime-types": { + "version": "2.1.17", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.17.tgz", + "integrity": "sha1-Cdejk/A+mVp5+K+Fe3Cp4KsWVXo=", + "requires": { + "mime-db": "1.30.0" + } + }, + "mimic-fn": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-1.1.0.tgz", + "integrity": "sha1-5md4PZLonb00KBi1IwudYqZyrRg=" + }, + "minimatch": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", + "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", + "requires": { + "brace-expansion": "1.1.8" + } + }, + "minimist": { + "version": "0.0.10", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.10.tgz", + "integrity": "sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8=" + }, + "mixin-deep": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/mixin-deep/-/mixin-deep-1.3.0.tgz", + "integrity": "sha512-dgaCvoh6i1nosAUBKb0l0pfJ78K8+S9fluyIR2YvAeUD/QuMahnFnF3xYty5eYXMjhGSsB0DsW6A0uAZyetoAg==", + "requires": { + "for-in": "1.0.2", + "is-extendable": "1.0.1" + }, + "dependencies": { + "is-extendable": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-1.0.1.tgz", + "integrity": "sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==", + "requires": { + "is-plain-object": "2.0.4" + } + } + } + }, + "mkdirp": { + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", + "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", + "requires": { + "minimist": "0.0.8" + }, + "dependencies": { + "minimist": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", + "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=" + } + } + }, + "ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" + }, + "nanomatch": { + "version": "1.2.6", + "resolved": "https://registry.npmjs.org/nanomatch/-/nanomatch-1.2.6.tgz", + "integrity": "sha512-WJ6XTCbvWXUFPbi/bDwKcYkCeOGUHzaJj72KbuPqGn78Ba/F5Vu26Zlo6SuMQbCIst1RGKL1zfWBCOGAlbRLAg==", + "requires": { + "arr-diff": "4.0.0", + "array-unique": "0.3.2", + "define-property": "1.0.0", + "extend-shallow": "2.0.1", + "fragment-cache": "0.2.1", + "is-odd": "1.0.0", + "kind-of": "5.1.0", + "object.pick": "1.3.0", + "regex-not": "1.0.0", + "snapdragon": "0.8.1", + "to-regex": "3.0.1" + }, + "dependencies": { + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==" + } + } + }, + "natural-compare": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", + "integrity": "sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc=" + }, + "nise": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/nise/-/nise-1.2.0.tgz", + "integrity": "sha512-q9jXh3UNsMV28KeqI43ILz5+c3l+RiNW8mhurEwCKckuHQbL+hTJIKKTiUlCPKlgQ/OukFvSnKB/Jk3+sFbkGA==", + "requires": { + "formatio": "1.2.0", + "just-extend": "1.1.27", + "lolex": "1.6.0", + "path-to-regexp": "1.7.0", + "text-encoding": "0.6.4" + }, + "dependencies": { + "lolex": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/lolex/-/lolex-1.6.0.tgz", + "integrity": "sha1-OpoCg0UqR9dDnnJzG54H1zhuSfY=" + } + } + }, + "node-int64": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz", + "integrity": "sha1-h6kGXNs1XTGC2PlM4RGIuCXGijs=" + }, + "node-notifier": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/node-notifier/-/node-notifier-5.1.2.tgz", + "integrity": "sha1-L6nhJgX6EACdRFSdb82KY93g5P8=", + "requires": { + "growly": "1.3.0", + "semver": "5.4.1", + "shellwords": "0.1.1", + "which": "1.3.0" + } + }, + "normalize-package-data": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.4.0.tgz", + "integrity": "sha512-9jjUFbTPfEy3R/ad/2oNbKtW9Hgovl5O1FvFWKkKblNXoN/Oou6+9+KKohPK13Yc3/TyunyWhJp6gvRNR/PPAw==", + "requires": { + "hosted-git-info": "2.5.0", + "is-builtin-module": "1.0.0", + "semver": "5.4.1", + "validate-npm-package-license": "3.0.1" + } + }, + "normalize-path": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-2.1.1.tgz", + "integrity": "sha1-GrKLVW4Zg2Oowab35vogE3/mrtk=", + "requires": { + "remove-trailing-separator": "1.1.0" + } + }, + "npm-run-path": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz", + "integrity": "sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8=", + "requires": { + "path-key": "2.0.1" + } + }, + "number-is-nan": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", + "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=" + }, + "nwmatcher": { + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/nwmatcher/-/nwmatcher-1.4.3.tgz", + "integrity": "sha512-IKdSTiDWCarf2JTS5e9e2+5tPZGdkRJ79XjYV0pzK8Q9BpsFyBq1RGKxzs7Q8UBushGw7m6TzVKz6fcY99iSWw==" + }, + "oauth-sign": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.8.2.tgz", + "integrity": "sha1-Rqarfwrq2N6unsBWV4C31O/rnUM=" + }, + "object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=" + }, + "object-copy": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/object-copy/-/object-copy-0.1.0.tgz", + "integrity": "sha1-fn2Fi3gb18mRpBupde04EnVOmYw=", + "requires": { + "copy-descriptor": "0.1.1", + "define-property": "0.2.5", + "kind-of": "3.2.2" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "requires": { + "is-descriptor": "0.1.6" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "requires": { + "kind-of": "3.2.2" + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "requires": { + "kind-of": "3.2.2" + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + }, + "dependencies": { + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==" + } + } + }, + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "object-keys": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.0.11.tgz", + "integrity": "sha1-xUYBd4rVYPEULODgG8yotW0TQm0=" + }, + "object-visit": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/object-visit/-/object-visit-1.0.1.tgz", + "integrity": "sha1-95xEk68MU3e1n+OdOV5BBC3QRbs=", + "requires": { + "isobject": "3.0.1" + } + }, + "object.getownpropertydescriptors": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.0.3.tgz", + "integrity": "sha1-h1jIRvW0B62rDyNuCYbxSwUcqhY=", + "requires": { + "define-properties": "1.1.2", + "es-abstract": "1.10.0" + } + }, + "object.omit": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/object.omit/-/object.omit-2.0.1.tgz", + "integrity": "sha1-Gpx0SCnznbuFjHbKNXmuKlTr0fo=", + "requires": { + "for-own": "0.1.5", + "is-extendable": "0.1.1" + } + }, + "object.pick": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/object.pick/-/object.pick-1.3.0.tgz", + "integrity": "sha1-h6EKxMFpS9Lhy/U1kaZhQftd10c=", + "requires": { + "isobject": "3.0.1" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", + "requires": { + "wrappy": "1.0.2" + } + }, + "optimist": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/optimist/-/optimist-0.6.1.tgz", + "integrity": "sha1-2j6nRob6IaGaERwybpDrFaAZZoY=", + "requires": { + "minimist": "0.0.10", + "wordwrap": "0.0.3" + } + }, + "optionator": { + "version": "0.8.2", + "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.8.2.tgz", + "integrity": "sha1-NkxeQJ0/TWMB1sC0wFu6UBgK62Q=", + "requires": { + "deep-is": "0.1.3", + "fast-levenshtein": "2.0.6", + "levn": "0.3.0", + "prelude-ls": "1.1.2", + "type-check": "0.3.2", + "wordwrap": "1.0.0" + }, + "dependencies": { + "wordwrap": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-1.0.0.tgz", + "integrity": "sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus=" + } + } + }, + "os-homedir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", + "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=" + }, + "os-locale": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/os-locale/-/os-locale-2.1.0.tgz", + "integrity": "sha512-3sslG3zJbEYcaC4YVAvDorjGxc7tv6KVATnLPZONiljsUncvihe9BQoVCEs0RZ1kmf4Hk9OBqlZfJZWI4GanKA==", + "requires": { + "execa": "0.7.0", + "lcid": "1.0.0", + "mem": "1.1.0" + } + }, + "os-tmpdir": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", + "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=" + }, + "p-finally": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", + "integrity": "sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4=" + }, + "p-limit": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-1.1.0.tgz", + "integrity": "sha1-sH/y2aXYi+yAYDWJWiurZqJ5iLw=" + }, + "p-locate": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz", + "integrity": "sha1-IKAQOyIqcMj9OcwuWAaA893l7EM=", + "requires": { + "p-limit": "1.1.0" + } + }, + "parse-glob": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/parse-glob/-/parse-glob-3.0.4.tgz", + "integrity": "sha1-ssN2z7EfNVE7rdFz7wu246OIORw=", + "requires": { + "glob-base": "0.3.0", + "is-dotfile": "1.0.3", + "is-extglob": "1.0.0", + "is-glob": "2.0.1" + }, + "dependencies": { + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=" + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "requires": { + "is-extglob": "1.0.0" + } + } + } + }, + "parse-json": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-2.2.0.tgz", + "integrity": "sha1-9ID0BDTvgHQfhGkJn43qGPVaTck=", + "requires": { + "error-ex": "1.3.1" + } + }, + "parse5": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-3.0.3.tgz", + "integrity": "sha512-rgO9Zg5LLLkfJF9E6CCmXlSE4UVceloys8JrFqCcHloC3usd/kJCyPDwH2SOlzix2j3xaP9sUX3e8+kvkuleAA==", + "requires": { + "@types/node": "8.5.2" + } + }, + "pascalcase": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/pascalcase/-/pascalcase-0.1.1.tgz", + "integrity": "sha1-s2PlXoAGym/iF4TS2yK9FdeRfxQ=" + }, + "path-dirname": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/path-dirname/-/path-dirname-1.0.2.tgz", + "integrity": "sha1-zDPSTVJeCZpTiMAzbG4yuRYGCeA=" + }, + "path-exists": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=" + }, + "path-is-absolute": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" + }, + "path-key": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", + "integrity": "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=" + }, + "path-parse": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.5.tgz", + "integrity": "sha1-PBrfhx6pzWyUMbbqK9dKD/BVxME=" + }, + "path-to-regexp": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-1.7.0.tgz", + "integrity": "sha1-Wf3g9DW62suhA6hOnTvGTpa5k30=", + "requires": { + "isarray": "0.0.1" + }, + "dependencies": { + "isarray": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz", + "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=" + } + } + }, + "path-type": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/path-type/-/path-type-1.1.0.tgz", + "integrity": "sha1-WcRPfuSR2nBNpBXaWkBwuk+P5EE=", + "requires": { + "graceful-fs": "4.1.11", + "pify": "2.3.0", + "pinkie-promise": "2.0.1" + } + }, + "performance-now": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", + "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=" + }, + "pify": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz", + "integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw=" + }, + "pinkie": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/pinkie/-/pinkie-2.0.4.tgz", + "integrity": "sha1-clVrgM+g1IqXToDnckjoDtT3+HA=" + }, + "pinkie-promise": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/pinkie-promise/-/pinkie-promise-2.0.1.tgz", + "integrity": "sha1-ITXW36ejWMBprJsXh3YogihFD/o=", + "requires": { + "pinkie": "2.0.4" + } + }, + "pkg-dir": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-2.0.0.tgz", + "integrity": "sha1-9tXREJ4Z1j7fQo4L1X4Sd3YVM0s=", + "requires": { + "find-up": "2.1.0" + } + }, + "pn": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/pn/-/pn-1.0.0.tgz", + "integrity": "sha1-HPWjCw2AbNGPiPxBprXUrWFbO6k=" + }, + "posix-character-classes": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/posix-character-classes/-/posix-character-classes-0.1.1.tgz", + "integrity": "sha1-AerA/jta9xoqbAL+q7jB/vfgDqs=" + }, + "prelude-ls": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", + "integrity": "sha1-IZMqVJ9eUv/ZqCf1cOBL5iqX2lQ=" + }, + "preserve": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/preserve/-/preserve-0.2.0.tgz", + "integrity": "sha1-gV7R9uvGWSb4ZbMQwHE7yzMVzks=" + }, + "pretty-format": { + "version": "22.0.3", + "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-22.0.3.tgz", + "integrity": "sha512-qXbDFJ2/Kk3HFIaLdOblbsCKQ09kZu4MKbXB+m/EaqD7PZ/wXe2XcRREmQleMh4wmerxlma6eJTh3nxCXYUmmA==", + "requires": { + "ansi-regex": "3.0.0", + "ansi-styles": "3.2.0" + }, + "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" + }, + "ansi-styles": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.0.tgz", + "integrity": "sha512-NnSOmMEYtVR2JVMIGTzynRkkaxtiq1xnFBcdQD/DnNCYPoEPsVJhM98BDyaoNOQIi7p4okdi3E27eN7GQbsUug==", + "requires": { + "color-convert": "1.9.1" + } + } + } + }, + "private": { + "version": "0.1.8", + "resolved": "https://registry.npmjs.org/private/-/private-0.1.8.tgz", + "integrity": "sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg==" + }, + "process-nextick-args": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz", + "integrity": "sha1-FQ4gt1ZZCtP5EJPyWk8q2L/zC6M=" + }, + "pseudomap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz", + "integrity": "sha1-8FKijacOYYkX7wqKw0wa5aaChrM=" + }, + "punycode": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", + "integrity": "sha1-wNWmOycYgArY4esPpSachN1BhF4=" + }, + "qs": { + "version": "6.5.1", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.1.tgz", + "integrity": "sha512-eRzhrN1WSINYCDCbrz796z37LOe3m5tmW7RQf6oBntukAG1nmovJvhnwHHRMAfeoItc1m2Hk02WER2aQ/iqs+A==" + }, + "randomatic": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/randomatic/-/randomatic-1.1.7.tgz", + "integrity": "sha512-D5JUjPyJbaJDkuAazpVnSfVkLlpeO3wDlPROTMLGKG1zMFNFRgrciKo1ltz/AzNTkqE0HzDx655QOL51N06how==", + "requires": { + "is-number": "3.0.0", + "kind-of": "4.0.0" + }, + "dependencies": { + "kind-of": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-4.0.0.tgz", + "integrity": "sha1-IIE989cSkosgc3hpGkUGb65y3Vc=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "read-package-json": { + "version": "2.0.12", + "resolved": "https://registry.npmjs.org/read-package-json/-/read-package-json-2.0.12.tgz", + "integrity": "sha512-m7/I0+tP6D34EVvSlzCtuVA4D/dHL6OpLcn2e4XVP5X57pCKGUy1JjRSBVKHWpB+vUU91sL85h84qX0MdXzBSw==", + "requires": { + "glob": "7.1.2", + "graceful-fs": "4.1.11", + "json-parse-better-errors": "1.0.1", + "normalize-package-data": "2.4.0", + "slash": "1.0.0" + } + }, + "read-pkg": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-1.1.0.tgz", + "integrity": "sha1-9f+qXs0pyzHAR0vKfXVra7KePyg=", + "requires": { + "load-json-file": "1.1.0", + "normalize-package-data": "2.4.0", + "path-type": "1.1.0" + } + }, + "read-pkg-up": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-1.0.1.tgz", + "integrity": "sha1-nWPBMnbAZZGNV/ACpX9AobZD+wI=", + "requires": { + "find-up": "1.1.2", + "read-pkg": "1.1.0" + }, + "dependencies": { + "find-up": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-1.1.2.tgz", + "integrity": "sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8=", + "requires": { + "path-exists": "2.1.0", + "pinkie-promise": "2.0.1" + } + }, + "path-exists": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-2.1.0.tgz", + "integrity": "sha1-D+tsZPD8UY2adU3V77YscCJ2H0s=", + "requires": { + "pinkie-promise": "2.0.1" + } + } + } + }, + "readable-stream": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.3.tgz", + "integrity": "sha512-m+qzzcn7KUxEmd1gMbchF+Y2eIUbieUaxkWtptyHywrX0rE8QEYqPC07Vuy4Wm32/xE16NcdBctb8S0Xe/5IeQ==", + "requires": { + "core-util-is": "1.0.2", + "inherits": "2.0.3", + "isarray": "1.0.0", + "process-nextick-args": "1.0.7", + "safe-buffer": "5.1.1", + "string_decoder": "1.0.3", + "util-deprecate": "1.0.2" + } + }, + "readdir-enhanced": { + "version": "1.5.2", + "resolved": "https://registry.npmjs.org/readdir-enhanced/-/readdir-enhanced-1.5.2.tgz", + "integrity": "sha1-YUYwSGkKxqRVt1ti+nioj43IXlM=", + "requires": { + "call-me-maybe": "1.0.1", + "es6-promise": "4.2.2", + "glob-to-regexp": "0.3.0" + } + }, + "readdirp": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-2.1.0.tgz", + "integrity": "sha1-TtCtBg3zBzMAxIRANz9y0cxkLXg=", + "requires": { + "graceful-fs": "4.1.11", + "minimatch": "3.0.4", + "readable-stream": "2.3.3", + "set-immediate-shim": "1.0.1" + } + }, + "realpath-native": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/realpath-native/-/realpath-native-1.0.0.tgz", + "integrity": "sha512-XJtlRJ9jf0E1H1SLeJyQ9PGzQD7S65h1pRXEcAeK48doKOnKxcgPeNohJvD5u/2sI9J1oke6E8bZHS/fmW1UiQ==", + "requires": { + "util.promisify": "1.0.0" + } + }, + "regenerator-runtime": { + "version": "0.11.1", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz", + "integrity": "sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg==" + }, + "regex-cache": { + "version": "0.4.4", + "resolved": "https://registry.npmjs.org/regex-cache/-/regex-cache-0.4.4.tgz", + "integrity": "sha512-nVIZwtCjkC9YgvWkpM55B5rBhBYRZhAaJbgcFYXXsHnbZ9UZI9nnVWYZpBlCqv9ho2eZryPnWrZGsOdPwVWXWQ==", + "requires": { + "is-equal-shallow": "0.1.3" + } + }, + "regex-not": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/regex-not/-/regex-not-1.0.0.tgz", + "integrity": "sha1-Qvg+OXcWIt+CawKvF2Ul1qXxV/k=", + "requires": { + "extend-shallow": "2.0.1" + } + }, + "remove-trailing-separator": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz", + "integrity": "sha1-wkvOKig62tW8P1jg1IJJuSN52O8=" + }, + "repeat-element": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/repeat-element/-/repeat-element-1.1.2.tgz", + "integrity": "sha1-7wiaF40Ug7quTZPrmLT55OEdmQo=" + }, + "repeat-string": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", + "integrity": "sha1-jcrkcOHIirwtYA//Sndihtp15jc=" + }, + "repeating": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/repeating/-/repeating-2.0.1.tgz", + "integrity": "sha1-UhTFOpJtNVJwdSf7q0FdvAjQbdo=", + "requires": { + "is-finite": "1.0.2" + } + }, + "request": { + "version": "2.83.0", + "resolved": "https://registry.npmjs.org/request/-/request-2.83.0.tgz", + "integrity": "sha512-lR3gD69osqm6EYLk9wB/G1W/laGWjzH90t1vEa2xuxHD5KUrSzp9pUSfTm+YC5Nxt2T8nMPEvKlhbQayU7bgFw==", + "requires": { + "aws-sign2": "0.7.0", + "aws4": "1.6.0", + "caseless": "0.12.0", + "combined-stream": "1.0.5", + "extend": "3.0.1", + "forever-agent": "0.6.1", + "form-data": "2.3.1", + "har-validator": "5.0.3", + "hawk": "6.0.2", + "http-signature": "1.2.0", + "is-typedarray": "1.0.0", + "isstream": "0.1.2", + "json-stringify-safe": "5.0.1", + "mime-types": "2.1.17", + "oauth-sign": "0.8.2", + "performance-now": "2.1.0", + "qs": "6.5.1", + "safe-buffer": "5.1.1", + "stringstream": "0.0.5", + "tough-cookie": "2.3.3", + "tunnel-agent": "0.6.0", + "uuid": "3.1.0" + } + }, + "request-promise-core": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/request-promise-core/-/request-promise-core-1.1.1.tgz", + "integrity": "sha1-Pu4AssWqgyOc+wTFcA2jb4HNCLY=", + "requires": { + "lodash": "4.17.4" + } + }, + "request-promise-native": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/request-promise-native/-/request-promise-native-1.0.5.tgz", + "integrity": "sha1-UoF3D2jgyXGeUWP9P6tIIhX0/aU=", + "requires": { + "request-promise-core": "1.1.1", + "stealthy-require": "1.1.1", + "tough-cookie": "2.3.3" + } + }, + "require-directory": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", + "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=" + }, + "require-main-filename": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-1.0.1.tgz", + "integrity": "sha1-l/cXtp1IeE9fUmpsWqj/3aBVpNE=" + }, + "resolve": { + "version": "1.5.0", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.5.0.tgz", + "integrity": "sha512-hgoSGrc3pjzAPHNBg+KnFcK2HwlHTs/YrAGUr6qgTVUZmXv1UEXXl0bZNBKMA9fud6lRYFdPGz0xXxycPzmmiw==", + "requires": { + "path-parse": "1.0.5" + } + }, + "resolve-url": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/resolve-url/-/resolve-url-0.2.1.tgz", + "integrity": "sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo=" + }, + "rimraf": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.2.tgz", + "integrity": "sha512-lreewLK/BlghmxtfH36YYVg1i8IAce4TI7oao75I1g245+6BctqTVQiBP3YUJ9C6DQOXJmkYR9X9fCLtCOJc5w==", + "requires": { + "glob": "7.1.2" + } + }, + "safe-buffer": { + "version": "5.1.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.1.tgz", + "integrity": "sha512-kKvNJn6Mm93gAczWVJg7wH+wGYWNrDHdWvpUmHyEsgCtIwwo3bqPtV4tR5tuPaUhTOo/kvhVwd8XwwOllGYkbg==" + }, + "samsam": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/samsam/-/samsam-1.3.0.tgz", + "integrity": "sha512-1HwIYD/8UlOtFS3QO3w7ey+SdSDFE4HRNLZoZRYVQefrOY3l17epswImeB1ijgJFQJodIaHcwkp3r/myBjFVbg==" + }, + "sane": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/sane/-/sane-2.2.0.tgz", + "integrity": "sha512-OSJxhHO0CgPUw3lUm3GhfREAfza45smvEI9ozuFrxKG10GHVo0ryW9FK5VYlLvxj0SV7HVKHW0voYJIRu27GWg==", + "requires": { + "anymatch": "1.3.2", + "exec-sh": "0.2.1", + "fb-watchman": "2.0.0", + "minimatch": "3.0.4", + "minimist": "1.2.0", + "walker": "1.0.7", + "watch": "0.18.0" + }, + "dependencies": { + "minimist": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=" + } + } + }, + "sax": { + "version": "1.2.4", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz", + "integrity": "sha512-NqVDv9TpANUjFm0N8uM5GxL36UgKi9/atZw+x7YFnQ8ckwFGKrl4xX4yWtrey3UJm5nP1kUbnYgLopqWNSRhWw==" + }, + "semver": { + "version": "5.4.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.4.1.tgz", + "integrity": "sha512-WfG/X9+oATh81XtllIo/I8gOiY9EXRdv1cQdyykeXK17YcUW3EXUAi2To4pcH6nZtJPr7ZOpM5OMyWJZm+8Rsg==" + }, + "set-blocking": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", + "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=" + }, + "set-getter": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/set-getter/-/set-getter-0.1.0.tgz", + "integrity": "sha1-12nBgsnVpR9AkUXy+6guXoboA3Y=", + "requires": { + "to-object-path": "0.3.0" + } + }, + "set-immediate-shim": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/set-immediate-shim/-/set-immediate-shim-1.0.1.tgz", + "integrity": "sha1-SysbJ+uAip+NzEgaWOXlb1mfP2E=" + }, + "set-value": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/set-value/-/set-value-2.0.0.tgz", + "integrity": "sha512-hw0yxk9GT/Hr5yJEYnHNKYXkIA8mVJgd9ditYZCe16ZczcaELYYcfvaXesNACk2O8O0nTiPQcQhGUQj8JLzeeg==", + "requires": { + "extend-shallow": "2.0.1", + "is-extendable": "0.1.1", + "is-plain-object": "2.0.4", + "split-string": "3.1.0" + } + }, + "shebang-command": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", + "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=", + "requires": { + "shebang-regex": "1.0.0" + } + }, + "shebang-regex": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", + "integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=" + }, + "shell-quote": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/shell-quote/-/shell-quote-1.6.1.tgz", + "integrity": "sha1-9HgZSczkAmlxJ0MOo7PFR29IF2c=", + "requires": { + "array-filter": "0.0.1", + "array-map": "0.0.0", + "array-reduce": "0.0.0", + "jsonify": "0.0.0" + } + }, + "shellwords": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/shellwords/-/shellwords-0.1.1.tgz", + "integrity": "sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==" + }, + "signal-exit": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.2.tgz", + "integrity": "sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0=" + }, + "simplr-logger": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/simplr-logger/-/simplr-logger-1.0.1.tgz", + "integrity": "sha512-lyDPiwbPi3jlOMj1Zufdmy60ibE3EyHgJ3nH/FzFNe9pfSz15mWYOt4FT860XFvxVQkZX7RxrqzPMoPSgAU3nQ==", + "requires": { + "tslib": "1.8.1" + } + }, + "simplr-tslint": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/simplr-tslint/-/simplr-tslint-0.0.1.tgz", + "integrity": "sha512-Piq9BsldiMj5oJVWqMZvxZhr1HBj+OMhzUNNrzkhqkg567dSBFZVHlJepy6IA2o4RpM3V85e/TWygQ9fyhAu7g==" + }, + "sinon": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/sinon/-/sinon-4.1.3.tgz", + "integrity": "sha512-c7u0ZuvBRX1eXuB4jN3BRCAOGiUTlM8SE3TxbJHrNiHUKL7wonujMOB6Fi1gQc00U91IscFORQHDga/eccqpbw==", + "requires": { + "diff": "3.4.0", + "formatio": "1.2.0", + "lodash.get": "4.4.2", + "lolex": "2.3.1", + "nise": "1.2.0", + "supports-color": "4.5.0", + "type-detect": "4.0.5" + }, + "dependencies": { + "supports-color": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-4.5.0.tgz", + "integrity": "sha1-vnoN5ITexcXN34s9WRJQRJEvY1s=", + "requires": { + "has-flag": "2.0.0" + } + } + } + }, + "slash": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-1.0.0.tgz", + "integrity": "sha1-xB8vbDn8FtHNF61LXYlhFK5HDVU=" + }, + "snapdragon": { + "version": "0.8.1", + "resolved": "https://registry.npmjs.org/snapdragon/-/snapdragon-0.8.1.tgz", + "integrity": "sha1-4StUh/re0+PeoKyR6UAL91tAE3A=", + "requires": { + "base": "0.11.2", + "debug": "2.6.9", + "define-property": "0.2.5", + "extend-shallow": "2.0.1", + "map-cache": "0.2.2", + "source-map": "0.5.7", + "source-map-resolve": "0.5.1", + "use": "2.0.2" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "requires": { + "is-descriptor": "0.1.6" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==" + } + } + }, + "snapdragon-node": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/snapdragon-node/-/snapdragon-node-2.1.1.tgz", + "integrity": "sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw==", + "requires": { + "define-property": "1.0.0", + "isobject": "3.0.1", + "snapdragon-util": "3.0.1" + } + }, + "snapdragon-util": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/snapdragon-util/-/snapdragon-util-3.0.1.tgz", + "integrity": "sha512-mbKkMdQKsjX4BAL4bRYTj21edOf8cN7XHdYUJEe+Zn99hVEYcMvKPct1IqNe7+AZPirn8BCDOQBHQZknqmKlZQ==", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "sntp": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/sntp/-/sntp-2.1.0.tgz", + "integrity": "sha512-FL1b58BDrqS3A11lJ0zEdnJ3UOKqVxawAkF3k7F0CVN7VQ34aZrV+G8BZ1WC9ZL7NyrwsW0oviwsWDgRuVYtJg==", + "requires": { + "hoek": "4.2.0" + } + }, + "source-map": { + "version": "0.5.7", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.7.tgz", + "integrity": "sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w=" + }, + "source-map-resolve": { + "version": "0.5.1", + "resolved": "https://registry.npmjs.org/source-map-resolve/-/source-map-resolve-0.5.1.tgz", + "integrity": "sha512-0KW2wvzfxm8NCTb30z0LMNyPqWCdDGE2viwzUaucqJdkTRXtZiSY3I+2A6nVAjmdOy0I4gU8DwnVVGsk9jvP2A==", + "requires": { + "atob": "2.0.3", + "decode-uri-component": "0.2.0", + "resolve-url": "0.2.1", + "source-map-url": "0.4.0", + "urix": "0.1.0" + } + }, + "source-map-support": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.0.tgz", + "integrity": "sha512-vUoN3I7fHQe0R/SJLKRdKYuEdRGogsviXFkHHo17AWaTGv17VLnxw+CFXvqy+y4ORZ3doWLQcxRYfwKrsd/H7Q==", + "requires": { + "source-map": "0.6.1" + }, + "dependencies": { + "source-map": { + "version": "0.6.1", + "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", + "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==" + } + } + }, + "source-map-url": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/source-map-url/-/source-map-url-0.4.0.tgz", + "integrity": "sha1-PpNdfd1zYxuXZZlW1VEo6HtQhKM=" + }, + "spdx-correct": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-1.0.2.tgz", + "integrity": "sha1-SzBz2TP/UfORLwOsVRlJikFQ20A=", + "requires": { + "spdx-license-ids": "1.2.2" + } + }, + "spdx-expression-parse": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-1.0.4.tgz", + "integrity": "sha1-m98vIOH0DtRH++JzJmGR/O1RYmw=" + }, + "spdx-license-ids": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-1.2.2.tgz", + "integrity": "sha1-yd96NCRZSt5r0RkA1ZZpbcBrrFc=" + }, + "split-string": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/split-string/-/split-string-3.1.0.tgz", + "integrity": "sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw==", + "requires": { + "extend-shallow": "3.0.2" + }, + "dependencies": { + "extend-shallow": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/extend-shallow/-/extend-shallow-3.0.2.tgz", + "integrity": "sha1-Jqcarwc7OfshJxcnRhMcJwQCjbg=", + "requires": { + "assign-symbols": "1.0.0", + "is-extendable": "1.0.1" + } + }, + "is-extendable": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-1.0.1.tgz", + "integrity": "sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==", + "requires": { + "is-plain-object": "2.0.4" + } + } + } + }, + "sprintf-js": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", + "integrity": "sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=" + }, + "sshpk": { + "version": "1.13.1", + "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.13.1.tgz", + "integrity": "sha1-US322mKHFEMW3EwY/hzx2UBzm+M=", + "requires": { + "asn1": "0.2.3", + "assert-plus": "1.0.0", + "dashdash": "1.14.1", + "getpass": "0.1.7" + } + }, + "stack-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/stack-utils/-/stack-utils-1.0.1.tgz", + "integrity": "sha1-1PM6tU6OOHeLDKXP07OvsS22hiA=" + }, + "static-extend": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/static-extend/-/static-extend-0.1.2.tgz", + "integrity": "sha1-YICcOcv/VTNyJv1eC1IPNB8ftcY=", + "requires": { + "define-property": "0.2.5", + "object-copy": "0.1.0" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "requires": { + "is-descriptor": "0.1.6" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==" + } + } + }, + "stealthy-require": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/stealthy-require/-/stealthy-require-1.1.1.tgz", + "integrity": "sha1-NbCYdbT/SfJqd35QmzCQoyJr8ks=" + }, + "string": { + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/string/-/string-3.3.3.tgz", + "integrity": "sha1-XqIRzZLSKOGEKUmQpsyXs2anfLA=" + }, + "string_decoder": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.0.3.tgz", + "integrity": "sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ==", + "requires": { + "safe-buffer": "5.1.1" + } + }, + "string-length": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/string-length/-/string-length-2.0.0.tgz", + "integrity": "sha1-1A27aGo6zpYMHP/KVivyxF+DY+0=", + "requires": { + "astral-regex": "1.0.0", + "strip-ansi": "4.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "requires": { + "ansi-regex": "3.0.0" + } + } + } + }, + "string-width": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", + "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "requires": { + "is-fullwidth-code-point": "2.0.0", + "strip-ansi": "4.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", + "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=" + }, + "is-fullwidth-code-point": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", + "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=" + }, + "strip-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", + "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", + "requires": { + "ansi-regex": "3.0.0" + } + } + } + }, + "stringstream": { + "version": "0.0.5", + "resolved": "https://registry.npmjs.org/stringstream/-/stringstream-0.0.5.tgz", + "integrity": "sha1-TkhM1N5aC7vuGORjB3EKioFiGHg=" + }, + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "requires": { + "ansi-regex": "2.1.1" + } + }, + "strip-bom": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-2.0.0.tgz", + "integrity": "sha1-YhmoVhZSBJHzV4i9vxRHqZx+aw4=", + "requires": { + "is-utf8": "0.2.1" + } + }, + "strip-eof": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", + "integrity": "sha1-u0P/VZim6wXYm1n80SnJgzE2Br8=" + }, + "subarg": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/subarg/-/subarg-1.0.0.tgz", + "integrity": "sha1-9izxdYHplrSPyWVpn1TAauJouNI=", + "requires": { + "minimist": "1.2.0" + }, + "dependencies": { + "minimist": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=" + } + } + }, + "supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=" + }, + "symbol-tree": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/symbol-tree/-/symbol-tree-3.2.2.tgz", + "integrity": "sha1-rifbOPZgp64uHDt9G8KQgZuFGeY=" + }, + "test-exclude": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-4.1.1.tgz", + "integrity": "sha512-35+Asrsk3XHJDBgf/VRFexPgh3UyETv8IAn/LRTiZjVy6rjPVqdEk8dJcJYBzl1w0XCJM48lvTy8SfEsCWS4nA==", + "requires": { + "arrify": "1.0.1", + "micromatch": "2.3.11", + "object-assign": "4.1.1", + "read-pkg-up": "1.0.1", + "require-main-filename": "1.0.1" + }, + "dependencies": { + "arr-diff": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/arr-diff/-/arr-diff-2.0.0.tgz", + "integrity": "sha1-jzuCf5Vai9ZpaX5KQlasPOrjVs8=", + "requires": { + "arr-flatten": "1.1.0" + } + }, + "array-unique": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.2.1.tgz", + "integrity": "sha1-odl8yvy8JiXMcPrc6zalDFiwGlM=" + }, + "braces": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/braces/-/braces-1.8.5.tgz", + "integrity": "sha1-uneWLhLf+WnWt2cR6RS3N4V79qc=", + "requires": { + "expand-range": "1.8.2", + "preserve": "0.2.0", + "repeat-element": "1.1.2" + } + }, + "expand-brackets": { + "version": "0.1.5", + "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-0.1.5.tgz", + "integrity": "sha1-3wcoTjQqgHzXM6xa9yQR5YHRF3s=", + "requires": { + "is-posix-bracket": "0.1.1" + } + }, + "extglob": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/extglob/-/extglob-0.3.2.tgz", + "integrity": "sha1-Lhj/PS9JqydlzskCPwEdqo2DSaE=", + "requires": { + "is-extglob": "1.0.0" + } + }, + "is-extglob": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", + "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=" + }, + "is-glob": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", + "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", + "requires": { + "is-extglob": "1.0.0" + } + }, + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + }, + "micromatch": { + "version": "2.3.11", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-2.3.11.tgz", + "integrity": "sha1-hmd8l9FyCzY0MdBNDRUpO9OMFWU=", + "requires": { + "arr-diff": "2.0.0", + "array-unique": "0.2.1", + "braces": "1.8.5", + "expand-brackets": "0.1.5", + "extglob": "0.3.2", + "filename-regex": "2.0.1", + "is-extglob": "1.0.0", + "is-glob": "2.0.1", + "kind-of": "3.2.2", + "normalize-path": "2.1.1", + "object.omit": "2.0.1", + "parse-glob": "3.0.4", + "regex-cache": "0.4.4" + } + } + } + }, + "text-encoding": { + "version": "0.6.4", + "resolved": "https://registry.npmjs.org/text-encoding/-/text-encoding-0.6.4.tgz", + "integrity": "sha1-45mpgiV6J22uQou5KEXLcb3CbRk=" + }, + "throat": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/throat/-/throat-4.1.0.tgz", + "integrity": "sha1-iQN8vJLFarGJJua6TLsgDhVnKmo=" + }, + "tmpl": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/tmpl/-/tmpl-1.0.4.tgz", + "integrity": "sha1-I2QN17QtAEM5ERQIIOXPRA5SHdE=" + }, + "to-fast-properties": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-1.0.3.tgz", + "integrity": "sha1-uDVx+k2MJbguIxsG46MFXeTKGkc=" + }, + "to-object-path": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/to-object-path/-/to-object-path-0.3.0.tgz", + "integrity": "sha1-KXWIt7Dn4KwI4E5nL4XB9JmeF68=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "to-regex": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/to-regex/-/to-regex-3.0.1.tgz", + "integrity": "sha1-FTWL7kosg712N3uh3ASdDxiDeq4=", + "requires": { + "define-property": "0.2.5", + "extend-shallow": "2.0.1", + "regex-not": "1.0.0" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "requires": { + "is-descriptor": "0.1.6" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==" + } + } + }, + "to-regex-range": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-2.1.1.tgz", + "integrity": "sha1-fIDBe53+vlmeJzZ+DU3VWQFB2zg=", + "requires": { + "is-number": "3.0.0", + "repeat-string": "1.6.1" + } + }, + "tough-cookie": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.3.3.tgz", + "integrity": "sha1-C2GKVWW23qkL80JdBNVe3EdadWE=", + "requires": { + "punycode": "1.4.1" + } + }, + "tr46": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-1.0.1.tgz", + "integrity": "sha1-qLE/1r/SSJUZZ0zN5VujaTtwbQk=", + "requires": { + "punycode": "2.1.0" + }, + "dependencies": { + "punycode": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.0.tgz", + "integrity": "sha1-X4Y+3Im5bbCQdLrXlHvwkFbKTn0=" + } + } + }, + "trim-right": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/trim-right/-/trim-right-1.0.1.tgz", + "integrity": "sha1-yy4SAwZ+DI3h9hQJS5/kVwTqYAM=" + }, + "ts-extractor": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/ts-extractor/-/ts-extractor-3.1.1.tgz", + "integrity": "sha512-5rU/I/f0JbbddHb0v1b5bJX+/b37VWP9vBpOQPAUVxDCV1eJ4MlKeVcgBAFajL76z9BxZVNXMHvyOtLUcEwHDw==", + "requires": { + "@types/fs-extra": "5.0.0", + "fs-extra": "5.0.0", + "read-package-json": "2.0.12", + "simplr-logger": "1.0.1", + "typescript": "2.6.2" + }, + "dependencies": { + "@types/fs-extra": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/@types/fs-extra/-/fs-extra-5.0.0.tgz", + "integrity": "sha512-qtxDULQKUenuaDLW003CgC+0T0eiAfH3BrH+vSt87GLzbz5EZ6Ox6mv9rMttvhDOatbb9nYh0E1m7ydoYwUrAg==", + "requires": { + "@types/node": "8.5.2" + } + }, + "fs-extra": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-5.0.0.tgz", + "integrity": "sha512-66Pm4RYbjzdyeuqudYqhFiNBbCIuI9kgRqLPSHIlXHidW8NIQtVdkM1yeZ4lXwuhbTETv3EUGMNHAAw6hiundQ==", + "requires": { + "graceful-fs": "4.1.11", + "jsonfile": "4.0.0", + "universalify": "0.1.1" + } + } + } + }, + "ts-jest": { + "version": "22.0.0", + "resolved": "https://registry.npmjs.org/ts-jest/-/ts-jest-22.0.0.tgz", + "integrity": "sha512-ATHKHtTzJPczvIj/4xrQxyTvmCUo/NL8pf5KWgLNLQX3dZYA65oJm9liBnegZLfphdhFerCKRtuBFGsmghYy1Q==", + "requires": { + "babel-core": "6.26.0", + "babel-plugin-istanbul": "4.1.5", + "babel-plugin-transform-es2015-modules-commonjs": "6.26.0", + "babel-preset-jest": "22.0.3", + "cpx": "1.5.0", + "fs-extra": "4.0.3", + "jest-config": "22.0.4", + "pkg-dir": "2.0.0", + "source-map-support": "0.5.0", + "yargs": "10.0.3" + } + }, + "tslib": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.8.1.tgz", + "integrity": "sha1-aUavLR1lGnsYY7Ux1uWvpBqkTqw=" + }, + "tslint": { + "version": "5.8.0", + "resolved": "https://registry.npmjs.org/tslint/-/tslint-5.8.0.tgz", + "integrity": "sha1-H0mtWy53x2w69N3K5VKuTjYS6xM=", + "requires": { + "babel-code-frame": "6.26.0", + "builtin-modules": "1.1.1", + "chalk": "2.3.0", + "commander": "2.12.2", + "diff": "3.4.0", + "glob": "7.1.2", + "minimatch": "3.0.4", + "resolve": "1.5.0", + "semver": "5.4.1", + "tslib": "1.8.1", + "tsutils": "2.15.0" + } + }, + "tsutils": { + "version": "2.15.0", + "resolved": "https://registry.npmjs.org/tsutils/-/tsutils-2.15.0.tgz", + "integrity": "sha512-kKb1mSqRMwF0GHKya5/hZsI2m7Flg4ONZDeYu4e6Gx+kYAu86zsLNCHcUmNWhCRaUcKshNI272hOzuaCQDzJ2g==", + "requires": { + "tslib": "1.8.1" + } + }, + "tunnel-agent": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", + "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=", + "requires": { + "safe-buffer": "5.1.1" + } + }, + "type-check": { + "version": "0.3.2", + "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.3.2.tgz", + "integrity": "sha1-WITKtRLPHTVeP7eE8wgEsrUg23I=", + "requires": { + "prelude-ls": "1.1.2" + } + }, + "type-detect": { + "version": "4.0.5", + "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.5.tgz", + "integrity": "sha512-N9IvkQslUGYGC24RkJk1ba99foK6TkwC2FHAEBlQFBP0RxQZS8ZpJuAZcwiY/w9ZJHFQb1aOXBI60OdxhTrwEQ==" + }, + "typescript": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-2.6.2.tgz", + "integrity": "sha1-PFtv1/beCRQmkCfwPAlGdY92c6Q=" + }, + "union-value": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/union-value/-/union-value-1.0.0.tgz", + "integrity": "sha1-XHHDTLW61dzr4+oM0IIHulqhrqQ=", + "requires": { + "arr-union": "3.1.0", + "get-value": "2.0.6", + "is-extendable": "0.1.1", + "set-value": "0.4.3" + }, + "dependencies": { + "set-value": { + "version": "0.4.3", + "resolved": "https://registry.npmjs.org/set-value/-/set-value-0.4.3.tgz", + "integrity": "sha1-fbCPnT0i3H945Trzw79GZuzfzPE=", + "requires": { + "extend-shallow": "2.0.1", + "is-extendable": "0.1.1", + "is-plain-object": "2.0.4", + "to-object-path": "0.3.0" + } + } + } + }, + "universalify": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.1.tgz", + "integrity": "sha1-+nG63UQ3r0wUiEHjs7Fl+enlkLc=" + }, + "unset-value": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/unset-value/-/unset-value-1.0.0.tgz", + "integrity": "sha1-g3aHP30jNRef+x5vw6jtDfyKtVk=", + "requires": { + "has-value": "0.3.1", + "isobject": "3.0.1" + }, + "dependencies": { + "has-value": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/has-value/-/has-value-0.3.1.tgz", + "integrity": "sha1-ex9YutpiyoJ+wKIHgCVlSEWZXh8=", + "requires": { + "get-value": "2.0.6", + "has-values": "0.1.4", + "isobject": "2.1.0" + }, + "dependencies": { + "isobject": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/isobject/-/isobject-2.1.0.tgz", + "integrity": "sha1-8GVWEJaj8dou9GJy+BXIQNh+DIk=", + "requires": { + "isarray": "1.0.0" + } + } + } + }, + "has-values": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/has-values/-/has-values-0.1.4.tgz", + "integrity": "sha1-bWHeldkd/Km5oCCJrThL/49it3E=" + } + } + }, + "urix": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/urix/-/urix-0.1.0.tgz", + "integrity": "sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI=" + }, + "use": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/use/-/use-2.0.2.tgz", + "integrity": "sha1-riig1y+TvyJCKhii43mZMRLeyOg=", + "requires": { + "define-property": "0.2.5", + "isobject": "3.0.1", + "lazy-cache": "2.0.2" + }, + "dependencies": { + "define-property": { + "version": "0.2.5", + "resolved": "https://registry.npmjs.org/define-property/-/define-property-0.2.5.tgz", + "integrity": "sha1-w1se+RjsPJkPmlvFe+BKrOxcgRY=", + "requires": { + "is-descriptor": "0.1.6" + } + }, + "is-accessor-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-0.1.6.tgz", + "integrity": "sha1-qeEss66Nh2cn7u84Q/igiXtcmNY=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-data-descriptor": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-0.1.4.tgz", + "integrity": "sha1-C17mSDiOLIYCgueT8YVv7D8wG1Y=", + "requires": { + "kind-of": "3.2.2" + }, + "dependencies": { + "kind-of": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", + "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", + "requires": { + "is-buffer": "1.1.6" + } + } + } + }, + "is-descriptor": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-0.1.6.tgz", + "integrity": "sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==", + "requires": { + "is-accessor-descriptor": "0.1.6", + "is-data-descriptor": "0.1.4", + "kind-of": "5.1.0" + } + }, + "kind-of": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-5.1.0.tgz", + "integrity": "sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==" + } + } + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" + }, + "util.promisify": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/util.promisify/-/util.promisify-1.0.0.tgz", + "integrity": "sha512-i+6qA2MPhvoKLuxnJNpXAGhg7HphQOSUq2LKMZD0m15EiskXUkMvKdF4Uui0WYeCUGea+o2cw/ZuwehtfsrNkA==", + "requires": { + "define-properties": "1.1.2", + "object.getownpropertydescriptors": "2.0.3" + } + }, + "uuid": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.1.0.tgz", + "integrity": "sha512-DIWtzUkw04M4k3bf1IcpS2tngXEL26YUD2M0tMDUpnUrz2hgzUBlD55a4FjdLGPvfHxS6uluGWvaVEqgBcVa+g==" + }, + "validate-npm-package-license": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.1.tgz", + "integrity": "sha1-KAS6vnEq0zeUWaz74kdGqywwP7w=", + "requires": { + "spdx-correct": "1.0.2", + "spdx-expression-parse": "1.0.4" + } + }, + "verror": { + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", + "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=", + "requires": { + "assert-plus": "1.0.0", + "core-util-is": "1.0.2", + "extsprintf": "1.3.0" + } + }, + "walker": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/walker/-/walker-1.0.7.tgz", + "integrity": "sha1-L3+bj9ENZ3JisYqITijRlhjgKPs=", + "requires": { + "makeerror": "1.0.11" + } + }, + "watch": { + "version": "0.18.0", + "resolved": "https://registry.npmjs.org/watch/-/watch-0.18.0.tgz", + "integrity": "sha1-KAlUdsbffJDJYxOJkMClQj60uYY=", + "requires": { + "exec-sh": "0.2.1", + "minimist": "1.2.0" + }, + "dependencies": { + "minimist": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", + "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=" + } + } + }, + "webidl-conversions": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-4.0.2.tgz", + "integrity": "sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg==" + }, + "whatwg-encoding": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-1.0.3.tgz", + "integrity": "sha512-jLBwwKUhi8WtBfsMQlL4bUUcT8sMkAtQinscJAe/M4KHCkHuUJAF6vuB0tueNIw4c8ziO6AkRmgY+jL3a0iiPw==", + "requires": { + "iconv-lite": "0.4.19" + } + }, + "whatwg-url": { + "version": "6.4.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-6.4.0.tgz", + "integrity": "sha512-Z0CVh/YE217Foyb488eo+iBv+r7eAQ0wSTyApi9n06jhcA3z6Nidg/EGvl0UFkg7kMdKxfBzzr+o9JF+cevgMg==", + "requires": { + "lodash.sortby": "4.7.0", + "tr46": "1.0.1", + "webidl-conversions": "4.0.2" + } + }, + "which": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/which/-/which-1.3.0.tgz", + "integrity": "sha512-xcJpopdamTuY5duC/KnTTNBraPK54YwpenP4lzxU8H91GudWpFv38u0CKjclE1Wi2EH2EDz5LRcHcKbCIzqGyg==", + "requires": { + "isexe": "2.0.0" + } + }, + "which-module": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", + "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=" + }, + "wordwrap": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/wordwrap/-/wordwrap-0.0.3.tgz", + "integrity": "sha1-o9XabNXAvAAI03I0u68b7WMFkQc=" + }, + "wrap-ansi": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz", + "integrity": "sha1-2Pw9KE3QV5T+hJc8rs3Rz4JP3YU=", + "requires": { + "string-width": "1.0.2", + "strip-ansi": "3.0.1" + }, + "dependencies": { + "string-width": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", + "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", + "requires": { + "code-point-at": "1.1.0", + "is-fullwidth-code-point": "1.0.0", + "strip-ansi": "3.0.1" + } + } + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" + }, + "write-file-atomic": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.3.0.tgz", + "integrity": "sha512-xuPeK4OdjWqtfi59ylvVL0Yn35SF3zgcAcv7rBPFHVaEapaDr4GdGgm3j7ckTwH9wHL7fGmgfAnb0+THrHb8tA==", + "requires": { + "graceful-fs": "4.1.11", + "imurmurhash": "0.1.4", + "signal-exit": "3.0.2" + } + }, + "xml-name-validator": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/xml-name-validator/-/xml-name-validator-2.0.1.tgz", + "integrity": "sha1-TYuPHszTQZqjYgYb7O9RXh5VljU=" + }, + "y18n": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/y18n/-/y18n-3.2.1.tgz", + "integrity": "sha1-bRX7qITAhnnA136I53WegR4H+kE=" + }, + "yallist": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz", + "integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=" + }, + "yargs": { + "version": "10.0.3", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-10.0.3.tgz", + "integrity": "sha512-DqBpQ8NAUX4GyPP/ijDGHsJya4tYqLQrjPr95HNsr1YwL3+daCfvBwg7+gIC6IdJhR2kATh3hb61vjzMWEtjdw==", + "requires": { + "cliui": "3.2.0", + "decamelize": "1.2.0", + "find-up": "2.1.0", + "get-caller-file": "1.0.2", + "os-locale": "2.1.0", + "require-directory": "2.1.1", + "require-main-filename": "1.0.1", + "set-blocking": "2.0.0", + "string-width": "2.1.1", + "which-module": "2.0.0", + "y18n": "3.2.1", + "yargs-parser": "8.1.0" + } + }, + "yargs-parser": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-8.1.0.tgz", + "integrity": "sha512-yP+6QqN8BmrgW2ggLtTbdrOyBNSI7zBa4IykmiV5R1wl1JWNxQvWhMfMdmzIYtKU7oP3OOInY/tl2ov3BDjnJQ==", + "requires": { + "camelcase": "4.1.0" + } + } + } +} diff --git a/common/schemas/command-line.schema.json b/common/schemas/command-line.schema.json new file mode 100644 index 00000000..b817a03d --- /dev/null +++ b/common/schemas/command-line.schema.json @@ -0,0 +1,155 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "title": "Rush Configuration", + "description": "Configuration file for the Rush multi-package build tool", + + "type": "object", + "additionalProperties": false, + + "properties": { + "$schema": { + "description": "Part of the JSON Schema standard, this optional keyword declares the URL of the schema that the file conforms to. Editors may download the schema and use it to perform syntax highlighting.", + "type": "string" + }, + + "customCommands": { + "title": "Custom Commands", + "description": "A list of custom commands that can be invoked from the Rush command line", + "type": "array", + "items": { + "title": "Custom Command", + "type": "object", + "additionalProperties": false, + "required": [ "name", "summary", "documentation", "parallelized" ], + "properties": { + "name": { + "title": "Custom Command Name", + "description": "The name of the custom command, which can be invoked via \"rush \"", + "type": "string" + }, + "summary": { + "title": "Custom Command Summary", + "description": "A short summary of the custom command, which will appear when printing command line usage (e.g. \"rush --help\")", + "type": "string" + }, + "documentation": { + "title": "Custom Command Documentation", + "description": "A detailed description of the command, which appears when requesting command-line help for this command. If omitted, the summary will be used.", + "type": "string" + }, + "parallelized": { + "title": "Is Parallelized", + "description": "Describes whether or not this command can be run in parallel (with multiple instances running on several projects simultaneously). Defaults to 'true'.", + "type": "boolean" + } + } + } + }, + + "customOptions": { + "title": "Custom Options", + "description": "A list of custom options that can be associated with commands", + "type": "object", + "additionalProperties": false, + "patternProperties": { + "^--[a-zA-Z0-9]+(-[a-zA-Z0-9]+)*$": { + "title": "Custom Option", + "type": "object", + + "required": [ + "description", + "associatedCommands" + ], + + "properties": { + "description": { + "title": "Description", + "type": "string" + }, + + "associatedCommands": { + "title": "Supported Commands", + "description": "A list of commands which this option can be used with", + "type": "array", + "minItems": 1, + "items": { + "type": "string" + } + }, + + "shortName": { + "title": "Shortened Name", + "description": "A optional shortened value for the flag (e.g. --verbose might become -v)", + "type": "string", + "pattern": "^-[a-zA-Z0-9]+(-[a-zA-Z0-9]+)*$" + }, + + "optionType": { + "type": "string", + "enum": [ + "flag", + "enum" + ] + } + }, + + "oneOf": [ + { + "type": "object", + "required": [ "optionType" ], + "properties": { + "optionType": { + "type": "string", + "enum": [ + "flag" + ] + } + } + }, + { + "type": "object", + "required": [ "optionType", "enumValues" ], + "properties": { + "optionType": { + "type": "string", + "enum": [ + "enum" + ] + }, + + "enumValues": { + "title": "Enum Values", + "description": "A list of possible options for this flag", + "type": "array", + "minItems": 1, + + "items": { + "type": "object", + "additionalProperties": false, + "required": [ "name", "description" ], + "properties": { + "name": { + "title": "Name", + "type": "string" + }, + "description": { + "title": "Description", + "type": "string" + } + } + } + }, + + "defaultValue": { + "title": "Default Value", + "description": "If this flag is omitted, use this value by default", + "type": "string" + } + } + } + ] + } + } + } + } + } diff --git a/common/schemas/rush.schema.json b/common/schemas/rush.schema.json new file mode 100644 index 00000000..cb4b41bd --- /dev/null +++ b/common/schemas/rush.schema.json @@ -0,0 +1,205 @@ +{ + "$schema": "http://json-schema.org/draft-04/schema#", + "title": "Rush Configuration", + "description": "Configuration file for the Rush multi-package build tool", + "type": "object", + + "oneOf": [ + { + "type": "object", + "required": ["npmVersion"], + "properties": { + "npmVersion": { + "description": "The version of the NPM tool to install.", + "type": "string", + "pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$" + } + } + }, + { + "type": "object", + "required": ["pnpmVersion"], + "properties": { + "pnpmVersion": { + "description": "The version of the PNPM tool to install.", + "type": "string", + "pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$" + } + } + } + ], + + "properties": { + + "$schema": { + "description": "Part of the JSON Schema standard, this optional keyword declares the URL of the schema that the file conforms to. Editors may download the schema and use it to perform syntax highlighting.", + "type": "string" + }, + + "npmVersion": { + "type": "string" + }, + + "pnpmVersion": { + "type": "string" + }, + + "rushVersion": { + "description": "The version of the Rush tool that will be used to build this repository.", + "type": "string", + "pattern": "^[0-9]+\\.[0-9]+\\.[0-9]+$" + }, + "nodeSupportedVersionRange": { + "description": "A node-semver expression (e.g. \">=1.2.3 <2.0.0\", see https://github.com/npm/node-semver) indicating which versions of Node.js can safely be used to build this repository. If omitted, no validation is performed.", + "type": "string" + }, + "projectFolderMinDepth": { + "description": "The minimum folder depth for the projectFolder field. The default value is 1, i.e. no slashes in the path name.", + "type": "number" + }, + "hotfixChangeEnabled": { + "description": "Allows creation of hotfix changes. This feature is experimental so it is disabled by default.", + "type": "boolean" + }, + "projectFolderMaxDepth": { + "description": "The maximum folder depth for the projectFolder field. The default value is 2, i.e. a single slash in the path name.", + "type": "number" + }, + "approvedPackagesPolicy": { + "description": "Controls a package review workflow driven by the two config files \"browser-approved-packages.json\" and \"nonbrowser-approved-packages.json\"", + "type": "object", + "properties": { + "reviewCategories": { + "description": "A list of category names that can be applied to each project, and then referenced in \"browser-approved-packages.json\" and \"nonbrowser-approved-packages.json\"", + "type": "array", + "items": { + "type": "string" + } + }, + "ignoredNpmScopes": { + "description": "A list of NPM package scopes that will be excluded from review (e.g. \"@types\")", + "type": "array", + "items": { + "type": "string", + "pattern": "^@" + } + } + }, + "additionalProperties": false + }, + "gitPolicy": { + "description": "If the project is stored in a Git repository, additional settings related to Git", + "type": "object", + "properties": { + "allowedEmailRegExps": { + "description": "A list of regular expressions describing allowable e-mail patterns for Git commits. They are case-insensitive anchored JavaScript RegExps. Example: \".*@example\\.com\"", + "type": "array", + "items": { + "type": "string" + } + }, + "sampleEmail": { + "description": "An example valid e-mail address for \"Mr. Example\" that conforms to one of the allowedEmailRegExps. Example: \"mr-example@contoso\\.com\"", + "type": "string" + } + }, + "additionalProperties": false + }, + "repository": { + "description": "The repository location", + "type": "object", + "properties": { + "url": { + "description": "The remote url of the repository. If a value is provided, \"Rush change\" will use it to find the right remote to compare against.", + "type": "string" + } + }, + "additionalProperties": false + }, + "telemetryEnabled": { + "description": "Indicates whether telemetry data should be collected and stored in the Rush temp folder during Rush runs.", + "type": "boolean" + }, + "projects": { + "description": "A list of projects managed by this tool.", + "type": "array", + "items": { + "type": "object", + "properties": { + "packageName": { + "description": "The NPM package name of the project.", + "type": "string" + }, + "projectFolder": { + "description": "The path to the project folder relative to the Rush config file.", + "type": "string" + }, + "reviewCategory": { + "description": "An optional category for usage in the \"browser-approved-packages.json\" and \"nonbrowser-approved-packages.json\" files. Only strings from reviewCategories are allowed here.", + "type": "string" + }, + "cyclicDependencyProjects": { + "description": "A list of local projects that appear as devDependencies for this project, but cannot be locally linked because it would create a cyclic dependency; instead, the last published version will be installed in the Common folder.", + "type": "array", + "items": { + "type": "string" + } + }, + "shouldPublish": { + "description": "A flag indicating that changes to this project will be published to npm, which affects the Rush change and publish workflows.", + "type": "boolean" + }, + "versionPolicyName": { + "description": "An optional version policy associated with the project. Version policies are defined in \"version-policies.json file.", + "type": "string" + } + }, + "additionalProperties": false, + "required": [ + "packageName", + "projectFolder" + ] + } + }, + "eventHooks": { + "description": "Hooks are customized script actions that Rush executes when specific events occur.", + "type": "object", + "properties": { + "preRushInstall": { + "description": "The list of scripts to run before the Rush install command starts.", + "type": "array", + "items": { + "type": "string" + } + }, + "postRushInstall": { + "description": "The list of scripts to run after the Rush install command finishes.", + "type": "array", + "items": { + "type": "string" + } + }, + "preRushBuild": { + "description": "The list of scripts to run before the Rush build command starts.", + "type": "array", + "items": { + "type": "string" + } + }, + "postRushBuild": { + "description": "The list of scripts to run after the Rush build command finishes.", + "type": "array", + "items": { + "type": "string" + } + } + }, + "additionalProperties": false + } + }, + "additionalProperties": false, + "required": [ + "rushVersion", + "projects" + ] + } diff --git a/package.json b/package.json new file mode 100644 index 00000000..788a264d --- /dev/null +++ b/package.json @@ -0,0 +1,14 @@ +{ + "name": "ts-docs-gen-repo", + "version": "0.0.0", + "private": true, + "description": "Generating documentation for TypeScript code.", + "scripts": { + "test-ci": "rush test-ci", + "rush-rebuild": "rush rebuild", + "rush-install": "rush install" + }, + "devDependencies": { + "@microsoft/rush": "^4.0.1" + } +} diff --git a/packages/ts-docs-gen/.vscode/cSpell.json b/packages/ts-docs-gen/.vscode/cSpell.json new file mode 100644 index 00000000..5594aef4 --- /dev/null +++ b/packages/ts-docs-gen/.vscode/cSpell.json @@ -0,0 +1,19 @@ +// cSpell Settings +{ + // Version of the setting file. Always 0.1 + "version": "0.1", + // language - current active spelling language + "language": "en", + // words - list of words to be always considered correct + "words": [ + "AGPL", + "loglevel", + "simplrjs" + ], + // flagWords - list of words to be always considered incorrect + // This is useful for offensive words and common spelling errors. + // For example "hte" should be "the" + "flagWords": [ + "hte" + ] +} \ No newline at end of file diff --git a/packages/ts-docs-gen/.vscode/launch.json b/packages/ts-docs-gen/.vscode/launch.json new file mode 100644 index 00000000..2adcae64 --- /dev/null +++ b/packages/ts-docs-gen/.vscode/launch.json @@ -0,0 +1,19 @@ +{ + // Use IntelliSense to learn about possible Node.js debug attributes. + // Hover to view descriptions of existing attributes. + // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 + "version": "0.2.0", + "configurations": [ + { + "type": "node", + "request": "launch", + "name": "Launch Program", + "preLaunchTask": "build", + "program": "${workspaceRoot}\\src\\debug.ts", + "outFiles": [ + "${workspaceRoot}\\dist\\**\\*.js" + ], + "sourceMaps": true + } + ] +} diff --git a/packages/ts-docs-gen/.vscode/settings.json b/packages/ts-docs-gen/.vscode/settings.json new file mode 100644 index 00000000..75ded211 --- /dev/null +++ b/packages/ts-docs-gen/.vscode/settings.json @@ -0,0 +1,12 @@ +{ + "eslint.enable": false, + "typescript.tsdk": "node_modules\\typescript\\lib", + "files.exclude": { + "**/.git": true, + "**/.svn": true, + "**/.hg": true, + "**/CVS": true, + "**/.DS_Store": true, + "tests/**/__tests__/**/*.test.ts": true + } +} diff --git a/packages/ts-docs-gen/.vscode/tasks.json b/packages/ts-docs-gen/.vscode/tasks.json new file mode 100644 index 00000000..8a9f166d --- /dev/null +++ b/packages/ts-docs-gen/.vscode/tasks.json @@ -0,0 +1,15 @@ +{ + // See https://go.microsoft.com/fwlink/?LinkId=733558 + // for the documentation about the tasks.json format + "version": "2.0.0", + "tasks": [ + { + "label": "build", + "type": "npm", + "script": "build", + "problemMatcher": [ + "$tsc" + ] + } + ] +} diff --git a/README.md b/packages/ts-docs-gen/README.md similarity index 100% rename from README.md rename to packages/ts-docs-gen/README.md diff --git a/packages/ts-docs-gen/examples/simple/docs/api/exported-functions.md b/packages/ts-docs-gen/examples/simple/docs/api/exported-functions.md new file mode 100644 index 00000000..a613767a --- /dev/null +++ b/packages/ts-docs-gen/examples/simple/docs/api/exported-functions.md @@ -0,0 +1,26 @@ +# exported-functions + +## Functions + +### Foo() + +```typescript +function Foo(): string +``` + +**Return type** + +string + +---------- + +### Bar() + +```typescript +function Bar(): string +``` + +**Return type** + +string + diff --git a/packages/ts-docs-gen/examples/simple/docs/api/index.md b/packages/ts-docs-gen/examples/simple/docs/api/index.md new file mode 100644 index 00000000..65aac989 --- /dev/null +++ b/packages/ts-docs-gen/examples/simple/docs/api/index.md @@ -0,0 +1,632 @@ +[InterfaceDeclaration-16]: index.md#props +[InterfaceDeclaration-16]: index.md#props +[InterfaceDeclaration-1]: index.md#foo +[InterfaceDeclaration-2]: index.md#boo +[InterfaceDeclaration-4]: index.md#myconstrainttype +[InterfaceDeclaration-9]: index.md#dictionary +[InterfaceDeclaration-9]: index.md#dictionary +[InterfaceDeclaration-6]: index.md#objectsinterface +[InterfaceDeclaration-12]: index.md#monsterinterface +[ClassDeclaration-0]: index/hello.md#hello +# index + +## Functions + +### Component(arg) + +```typescript +function Component(arg: T): void +``` + +**Type parameters** + +| Name | Constraint type | Default type | +| ---- | -------------------------------- | -------------------------------- | +| T | [Props][InterfaceDeclaration-16] | [Props][InterfaceDeclaration-16] | + +**Parameters** + +| Name | Type | +| ---- | ---- | +| arg | T | + +**Return type** + +void + +## Interfaces + +### ExtendedBar + +```typescript +interface ExtendedBar extends Foo, Boo { + OtherStuff: string[]; +} +``` + +**Extends** + +[Foo][InterfaceDeclaration-1]<number> + +[Boo][InterfaceDeclaration-2] + +**Properties** + +| Name | Type | +| ---------- | --------------------- | +| OtherStuff | Array<string> | + +---------- + +### Foo + +```typescript +interface Foo { + Name: string; + Surname: string; + Type: TType; +} +``` + +**Type parameters** + +| Name | +| ----- | +| TType | + +**Properties** + +| Name | Type | +| ------- | ------ | +| Name | string | +| Surname | string | +| Type | TType | + +---------- + +### Boo + +```typescript +interface Boo { + Boos: string[]; +} +``` + +**Properties** + +| Name | Type | +| ---- | --------------------- | +| Boos | Array<string> | + +---------- + +### AnotherInterface + +```typescript +interface AnotherInterface { + (param1: TValue, param2: TValue): boolean; +} +``` + +#### Call + +```typescript +(param1: TValue, param2: TValue): boolean +``` + +**Type parameters** + +| Name | +| ------ | +| TValue | + +**Parameters** + +| Name | Type | +| ------ | ------ | +| param1 | TValue | +| param2 | TValue | + +**Return type** + +true | false + +---------- + +### MyConstraintType + +```typescript +interface MyConstraintType { + myProperty: string; +} +``` + +**Properties** + +| Name | Type | +| ---------- | ------ | +| myProperty | string | + +---------- + +### MyDefaultType + +```typescript +interface MyDefaultType extends MyConstraintType { + anotherProperty: number; +} +``` + +**Extends** + +[MyConstraintType][InterfaceDeclaration-4] + +**Properties** + +| Name | Type | +| --------------- | ------ | +| anotherProperty | number | + +---------- + +### ObjectsInterface + +```typescript +interface ObjectsInterface { + objectOne: Object; + objectTwo: Object; +} +``` + +**Properties** + +| Name | Type | +| --------- | ------ | +| objectOne | Object | +| objectTwo | Object | + +---------- + +### InterfaceWithCall + +```typescript +interface InterfaceWithCall { + (): { someProperty: T; }; +} +``` + +#### Call + +```typescript +(): { someProperty: T; } +``` + +**Type parameters** + +| Name | +| ---- | +| T | + +**Return type** + +{ someProperty: T; } + +---------- + +### InterfaceWithConstraintType + +```typescript +interface InterfaceWithConstraintType extends Dictionary { + someProperty: string; +} +``` + +**Extends** + +[Dictionary][InterfaceDeclaration-9]<string> + +**Properties** + +| Name | Type | +| ------------ | ------ | +| someProperty | string | + +---------- + +### InterfaceWithMethod + +```typescript +interface InterfaceWithMethod { + someMethodOne(): T; + someMethodTwo(): TReturn; +} +``` + +**Type parameters** + +| Name | +| ---- | +| T | + +#### Methods + +```typescript +someMethodOne(): T +``` + +**Return type** + +T + +```typescript +someMethodTwo(): TReturn +``` + +**Type parameters** + +| Name | +| ------- | +| TReturn | + +**Return type** + +TReturn + +---------- + +### Dictionary + +```typescript +interface Dictionary { + new (): Dictionary; + [key: string]: TValue; +} +``` + +**Type parameters** + +| Name | +| ------ | +| TValue | + +#### Construct + +```typescript +new (): Dictionary +``` + +**Return type** + +[Dictionary][InterfaceDeclaration-9]<TValue> + +#### Index signatures + +```typescript +[key: string]: TValue +``` + +* *Parameter* `key` - string +* *Type* TValue + +---------- + +### MethodsInterface + +```typescript +interface MethodsInterface { + (arg: TValue): void; + someMethod(): string; +} +``` + +#### Call + +```typescript +(arg: TValue): void +``` + +**Type parameters** + +| Name | +| ------ | +| TValue | + +**Parameters** + +| Name | Type | +| ---- | ------ | +| arg | TValue | + +**Return type** + +void + +#### Methods + +```typescript +someMethod(): string +``` + +**Type parameters** + +| Name | +| ---- | +| T | + +**Return type** + +string + +---------- + +### MonsterInterface + +Warning: Beta! + +Deprecated! + +Monster interface + +```typescript +interface MonsterInterface extends ObjectsInterface { + new (): MonsterInterface; + new (someParameter: string): string; + (): { someProperty: T; }; + (key?: string | undefined): { someProperty: T; }; + (key: number): { someProperty: T; }; + readonly [key: string]: TValue; + readonly objectOne: TValue; + objectTwo: TValue; +} +``` + +**Type parameters** + +| Name | Constraint type | Default type | +| ------ | --------------- | ------------ | +| TValue | Object | {} | + +**Extends** + +[ObjectsInterface][InterfaceDeclaration-6] + +#### Construct + +```typescript +new (): MonsterInterface +``` + +**Type parameters** + +| Name | +| ---- | +| T | + +**Return type** + +[MonsterInterface][InterfaceDeclaration-12]<T> + +```typescript +new (someParameter: string): string +``` + +**Parameters** + +| Name | Type | +| ------------- | ------ | +| someParameter | string | + +**Return type** + +string + +#### Call + +```typescript +(): { someProperty: T; } +``` + +**Type parameters** + +| Name | +| ---- | +| T | + +**Return type** + +{ someProperty: T; } + +```typescript +(key?: string | undefined): { someProperty: T; } +``` + +**Type parameters** + +| Name | +| ---- | +| T | + +**Parameters** + +| Name | Type | +| ---- | ----------------------- | +| key | undefined | string | + +**Return type** + +{ someProperty: T; } + +```typescript +(key: number): { someProperty: T; } +``` + +**Type parameters** + +| Name | +| ---- | +| T | + +**Parameters** + +| Name | Type | +| ---- | ------ | +| key | number | + +**Return type** + +{ someProperty: T; } + +#### Index signatures + +```typescript +readonly [key: string]: TValue +``` + +* *Parameter* `key` - string +* *Type* TValue + +**Properties** + +| Name | Type | +| --------- | ------ | +| objectOne | TValue | +| objectTwo | TValue | + +---------- + +### SomeInterface + +```typescript +interface SomeInterface { + [key: string]: string | number; + [key: number]: string; +} +``` + +#### Index signatures + +```typescript +[key: string]: string | number +``` + +* *Parameter* `key` - string +* *Type* string | number + +```typescript +[key: number]: string +``` + +* *Parameter* `key` - number +* *Type* string + +---------- + +### StringsDictionary + +```typescript +interface StringsDictionary { + [key: string]: string; +} +``` + +#### Index signatures + +```typescript +[key: string]: string +``` + +* *Parameter* `key` - string +* *Type* string + +---------- + +### MyInterface + +```typescript +interface MyInterface { + MyPropertyOne: string; + MyPropertyTwo: Object; + MyPropertyThree: number; +} +``` + +**Properties** + +| Name | Type | +| --------------- | ------ | +| MyPropertyOne | string | +| MyPropertyTwo | Object | +| MyPropertyThree | number | + +---------- + +### Props + +```typescript +interface Props { + name: string; +} +``` + +**Properties** + +| Name | Type | +| ---- | ------ | +| name | string | + +## Enums + +### Uogos + +Warning: Beta! + +Deprecated! + +Some information +2nd line of some information +3rd line of some information +4th line of some information +5th line of some information + +> Some summary about this package version. + + +```typescript +enum Uogos { + Jokie = "jokie", + Braskes = "braskes" +} +``` + +**Members** + +| Name | Value | +| ------- | --------- | +| Jokie | "jokie" | +| Braskes | "braskes" | + +---------- + +### ConstSkaiciai + + +```typescript +const enum ConstSkaiciai { + PirmasC = 0, + AntrasC = 1, + TreciasC = 2 +} +``` + +**Members** + +| Name | Value | +| -------- | ----- | +| PirmasC | 0 | +| AntrasC | 1 | +| TreciasC | 2 | + +## Classes + +### [Hello][ClassDeclaration-0] + diff --git a/packages/ts-docs-gen/examples/simple/docs/api/index/foonamespace.md b/packages/ts-docs-gen/examples/simple/docs/api/index/foonamespace.md new file mode 100644 index 00000000..c1c32a0e --- /dev/null +++ b/packages/ts-docs-gen/examples/simple/docs/api/index/foonamespace.md @@ -0,0 +1,7 @@ +[ModuleDeclaration-1]: foonamespace/boonamespace.md#boonamespace +# FooNamespace + +## Namespaces + +### [BooNamespace][ModuleDeclaration-1] + diff --git a/packages/ts-docs-gen/examples/simple/docs/api/index/foonamespace/boonamespace.md b/packages/ts-docs-gen/examples/simple/docs/api/index/foonamespace/boonamespace.md new file mode 100644 index 00000000..3ea42f39 --- /dev/null +++ b/packages/ts-docs-gen/examples/simple/docs/api/index/foonamespace/boonamespace.md @@ -0,0 +1,7 @@ +[ModuleDeclaration-2]: boonamespace/boonamespace2.md#boonamespace2 +# BooNamespace + +## Namespaces + +### [BooNamespace2][ModuleDeclaration-2] + diff --git a/packages/ts-docs-gen/examples/simple/docs/api/index/foonamespace/boonamespace/boonamespace2.md b/packages/ts-docs-gen/examples/simple/docs/api/index/foonamespace/boonamespace/boonamespace2.md new file mode 100644 index 00000000..a6a1066b --- /dev/null +++ b/packages/ts-docs-gen/examples/simple/docs/api/index/foonamespace/boonamespace/boonamespace2.md @@ -0,0 +1,14 @@ +# BooNamespace2 + +## Variables + +### Hello + +```typescript +const Hello: "World!"; +``` + +**Type** + +"World!" + diff --git a/packages/ts-docs-gen/examples/simple/docs/api/index/hello.md b/packages/ts-docs-gen/examples/simple/docs/api/index/hello.md new file mode 100644 index 00000000..a7c0022e --- /dev/null +++ b/packages/ts-docs-gen/examples/simple/docs/api/index/hello.md @@ -0,0 +1,49 @@ +# Hello + +```typescript +class Hello +``` +## Constructor + +### constructor(arg) + +This is a constructor + +```typescript +public constructor(arg: string) +``` + +**Parameters** + +| Name | Type | Description | +| ---- | ------ | ---------------------- | +| arg | string | This is an argument ;) | + +## Methods + +### render(arg) + +Warning: Beta! + +Comment about Render + +```typescript +public render(arg: T): T +``` + +**Type parameters** + +| Name | Constraint type | Default type | +| ---- | --------------- | ------------ | +| T | String | String | + +**Parameters** + +| Name | Type | Description | +| ---- | ---- | ---------------------- | +| arg | T | Argument comment here. | + +**Return type** + +T + diff --git a/packages/ts-docs-gen/examples/simple/exported-const-variables.ts b/packages/ts-docs-gen/examples/simple/exported-const-variables.ts new file mode 100644 index 00000000..42aca37f --- /dev/null +++ b/packages/ts-docs-gen/examples/simple/exported-const-variables.ts @@ -0,0 +1,6 @@ +/** + * First const variable in the exported items. + */ +export const Kintamasis = "Hello World!"; +export const Kintamasis2 = "World, Hello!"; +export const Kintamasis3 = "Not imported!"; diff --git a/packages/ts-docs-gen/examples/simple/exported-functions.ts b/packages/ts-docs-gen/examples/simple/exported-functions.ts new file mode 100644 index 00000000..6d5cdcfa --- /dev/null +++ b/packages/ts-docs-gen/examples/simple/exported-functions.ts @@ -0,0 +1,7 @@ +export function Foo(): string { + return "foo"; +} + +export function Bar(): string { + return "bar"; +} diff --git a/packages/ts-docs-gen/examples/simple/index.ts b/packages/ts-docs-gen/examples/simple/index.ts new file mode 100644 index 00000000..f3ac7c21 --- /dev/null +++ b/packages/ts-docs-gen/examples/simple/index.ts @@ -0,0 +1,324 @@ +// tslint:disable + +export interface ExtendedBar extends Foo, Boo { + OtherStuff: string[]; +} + +export interface Foo { + Name: string; + Surname: string; + Type: TType; +} + +export interface Boo { + Boos: string[]; +} + +export interface AnotherInterface { + (param1: TValue, param2: TValue): boolean; +} + +export interface MyConstraintType { + myProperty: string; +} + +export interface MyDefaultType extends MyConstraintType { + anotherProperty: number; +} + +export interface ObjectsInterface { + objectOne: Object; + objectTwo: Object; +} + +export interface InterfaceWithCall { + (): { someProperty: T }; +} + +export interface InterfaceWithConstraintType extends Dictionary { + someProperty: string; +} + +export interface InterfaceWithMethod { + someMethodOne(): T; + someMethodTwo(): TReturn; +} + +export interface Dictionary { + new(): Dictionary; + [key: string]: TValue; +} + +export interface MethodsInterface { + someMethod(): string; + (arg: TValue): void; +} + +/** + * Monster interface + * @beta + * @deprecated + */ +export interface MonsterInterface extends ObjectsInterface { + new (): MonsterInterface; + new(someParameter: string): string; + + readonly [key: string]: TValue; + + (): { someProperty: T }; + (key?: string): { someProperty: T }; + (key: number): { someProperty: T }; + + readonly objectOne: TValue; + objectTwo: TValue; +} + +export interface SomeInterface { + [key: string]: string | number; + [key: number]: string; +} + +export interface StringsDictionary { + [key: string]: string; +} + +export interface MyInterface { + MyPropertyOne: string; + MyPropertyTwo: Object; + MyPropertyThree: number; +} + + +// import { Foo } from "./exported-functions"; + +// export class World { } +// export class Earth { } +// export class Earth { } + +// export declare const Hello: World & Earth; + +// export const FooFunc = Foo; + +//--------------------------------------------------------- + + +// #region Parameters + +// #endregion Parameters + +// export function Foo(): string { +// return "foo"; +// } + +// /** +// * Some general comment about Bar function. +// * +// * @beta Some comment on beta. +// * @deprecated +// */ +// export function Bar(parameter1: string, parameter2: number): string { +// return "bar"; +// } + +// #region Return types +// export function FunctionWithoutReturnType>(parameter1: string, parameter2: Promise) { +// return "bar"; +// } + +// export function FunctionWithGenericReturnType(): Array { +// return []; +// } + +// export function FunctionWithPrimitiveReturnType(): boolean { +// return true; +// } + +// export function FunctionWithUnionReturnType(): "something" | "nothing" { +// return "nothing"; +// } + +// export function FunctionWithIntersectionReturnType(): Earth & World { +// return {}; +// } +// #endregion Return types + +// ------------------------------------------------------ + +// export * from "./exported-functions"; +// export { Kintamasis as Pakeistas } from "./exported-const-variables"; +// export type A = number & { ok(): TValue }; + +// Two types have a one common field +// export type OneCommonField1 = { +// BarName: string; +// FooName: string; +// }; + +// export type OneCommonField2 = { +// BarName: string; +// BazName: string; +// }; + +// export type OneCommonFieldTypeIntersection = OneCommonField1 | OneCommonField2; + +// export interface MyConstraintType { +// myProperty: string; +// } +// export interface MyDefaultType extends MyConstraintType { +// anotherProperty: number; +// } + +// export function MyFunction(): T { +// return { +// myProperty: "sampleString" +// } as T; +// } + +// export interface MyInterface { +// (param1: TValue, param2: TValue): boolean; +// } + +// /** +// * Some JSdoc information. +// * 2nd line of some JSdoc information. +// * @summary Some summary about this package version. +// * @summary 2nd of some summary about this package version. +// */ +// export const itemsList: string[] = ["a"]; + +// export function Ok(isIt: boolean): boolean { +// return isIt; +// } + +// export function OkWithoutReturnType(isIt: boolean) { +// return isIt; +// } + +// export namespace SomeKindOfModule { +// export const name = "some-kind-of-module"; +// } + +/** + * Some information + * 2nd line of some information + * 3rd line of some information + * 4th line of some information + * 5th line of some information + * @summary Some summary about this package version. + * @summary 2nd of some summary about this package version. + * @deprecated + * @beta + */ +export enum Uogos { + Jokie = "jokie", + Braskes = "braskes" +} + +// export enum Skaiciai { +// Nulis = 0, +// Vienas = 1, +// Du = 2 +// } + +// export enum Sarasas { +// /** +// * Pirmo description'as +// */ +// Pirmas, +// /** +// * Antro description'as +// */ +// Antras, +// /** +// * Trečio description'as +// */ +// Trecias +// } + +export const enum ConstSkaiciai { + PirmasC = 0, + AntrasC = 1, + TreciasC = 2 +} + +// export const enum ConstSarasas { +// /** +// * Pirmo description'as +// */ +// PirmasC, +// /** +// * Antro description'as +// */ +// AntrasC, +// /** +// * Trečio description'as +// */ +// TreciasC +// } + +// export interface Boo { +// Boos: string[]; +// } + +// export interface Foo { +// Name: string; +// Surname: string; +// Type: TType; +// } + +// export interface Bar extends Foo, Boo { +// OtherStuff: string[]; +// } + +// export interface A { +// (aa: boolean): string; +// } + +// export abstract class Foo { +// public Name: string; + +// private somePrivateProperty: any; + +// public GetName(ok: string): string; +// public GetName(ok: string, ok2?: string): string { +// return this.Name; +// } + +// public abstract Bar(): string; +// } + +// /** +// * @deprecated Use uogos instead ;) +// */ +// export type Hello = Uogos; + +export interface Props { + name: string; +} + +export function Component(arg: T): void { } + +export class Hello { + /** + * This is a constructor + * @param arg This is an argument ;) + */ + constructor(arg: string) { } + + /** + * Comment about Render + * @beta + * @param arg Argument comment here. + */ + public render(arg: T): T { + return arg; + } + + // get Foo(): string { + // throw new Error("Method not implemented."); + // } + + // set Foo(arg: string) { } + + // public static set Bar(arg: string) { } +} diff --git a/packages/ts-docs-gen/examples/simple/my-types.ts b/packages/ts-docs-gen/examples/simple/my-types.ts new file mode 100644 index 00000000..8295ca0d --- /dev/null +++ b/packages/ts-docs-gen/examples/simple/my-types.ts @@ -0,0 +1,3 @@ +export interface MyInterface { + foo: string; +} \ No newline at end of file diff --git a/packages/ts-docs-gen/examples/simple/package.json b/packages/ts-docs-gen/examples/simple/package.json new file mode 100644 index 00000000..c6cd7a97 --- /dev/null +++ b/packages/ts-docs-gen/examples/simple/package.json @@ -0,0 +1,6 @@ +{ + "name": "simple", + "dependencies": { + "react": "^15.6.1" + } +} diff --git a/packages/ts-docs-gen/examples/simple/tsconfig.json b/packages/ts-docs-gen/examples/simple/tsconfig.json new file mode 100644 index 00000000..f2f986af --- /dev/null +++ b/packages/ts-docs-gen/examples/simple/tsconfig.json @@ -0,0 +1,25 @@ +{ + "compilerOptions": { + "module": "commonjs", + "target": "es5", + "removeComments": false, + "outDir": "dist", + "rootDir": ".", + "sourceMap": false, + "skipDefaultLibCheck": true, + "declaration": true, + "pretty": true, + "strict": true, + "forceConsistentCasingInFileNames": true, + "lib": [ + "es6", + "dom" + ] + }, + "exclude": [ + "node_modules", + "dist", + "@types", + "__tests__" + ] +} diff --git a/packages/ts-docs-gen/package.json b/packages/ts-docs-gen/package.json new file mode 100644 index 00000000..17b691b8 --- /dev/null +++ b/packages/ts-docs-gen/package.json @@ -0,0 +1,62 @@ +{ + "name": "ts-docs-gen", + "version": "0.1.0", + "description": "Generating documentation for TypeScript code", + "main": "index.js", + "scripts": { + "pretest": "npm run build -- --noEmit && npm run build-tests", + "test": "npm run tslint && jest && echo All tests passed successfully.", + "test-ci": "npm run pretest && npm run tslint && jest --maxWorkers=4 -b", + "test-watch": "start npm run build-tests -- --watchAll && jest --watchAll", + "tslint": "tslint --project . --config ./tslint.json && echo Successfully passed tslint test.", + "build": "tsc -p .", + "build-tests": "node ../../tools/test-generator-cli/dist/index.js" + }, + "engine": "node >= 7.5.0", + "author": "simplrjs (https://github.com/simplrjs)", + "dependencies": { + "@simplrjs/markdown": "^1.0.7", + "@types/fs-extra": "^5.0.0", + "fast-glob": "^1.0.1", + "fs-extra": "^5.0.0", + "simplr-logger": "^1.0.1", + "ts-extractor": "^3.1.1", + "typescript": "^2.6.2" + }, + "devDependencies": { + "@types/jest": "^22.0.0", + "@types/sinon": "^4.1.2", + "jest": "^22.0.4", + "simplr-tslint": "0.0.1", + "sinon": "^4.1.3", + "ts-jest": "^22.0.0", + "tslint": "^5.8.0" + }, + "jest": { + "collectCoverage": true, + "mapCoverage": true, + "transform": { + ".(ts|tsx)": "/node_modules/ts-jest/preprocessor.js" + }, + "globals": { + "ts-jest": { + "skipBabel": true, + "tsConfigFile": "tests/tsconfig.json" + } + }, + "testRegex": "/__tests__/.*\\.(test|spec).(ts|tsx|js)$", + "moduleNameMapper": { + "@src/(.*)": "/src/$1" + }, + "coveragePathIgnorePatterns": [ + "/node_modules/", + "/tests/" + ], + "moduleFileExtensions": [ + "ts", + "tsx", + "js" + ], + "verbose": true + } +} diff --git a/packages/ts-docs-gen/src/abstractions/base-plugin.ts b/packages/ts-docs-gen/src/abstractions/base-plugin.ts new file mode 100644 index 00000000..bbfaebb8 --- /dev/null +++ b/packages/ts-docs-gen/src/abstractions/base-plugin.ts @@ -0,0 +1,83 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; + +import { Plugin, SupportedApiItemKindType, PluginOptions, PluginResult, PluginResultData } from "../contracts/plugin"; +import { GeneratorHelpers } from "../generator-helpers"; + +export abstract class BasePlugin implements Plugin { + public abstract SupportedApiItemKinds(): SupportedApiItemKindType[]; + + public CheckApiItem(item: TKind): boolean { + return true; + } + + // TODO: Escape string! + protected RenderTypeParameters(typeParameters: Contracts.ApiTypeParameterDto[]): PluginResultData | undefined { + if (typeParameters.length === 0) { + return undefined; + } + + const pluginResult = GeneratorHelpers.GetDefaultPluginResultData(); + const header = ["Name", "Constraint type", "Default type"]; + + const content = typeParameters.map(typeParameter => { + // ConstraintType + let constraintType: GeneratorHelpers.TypeToStringDto; + if (typeParameter.ConstraintType != null) { + constraintType = GeneratorHelpers.TypeDtoToMarkdownString(typeParameter.ConstraintType); + GeneratorHelpers.MergePluginResultData(pluginResult, { + UsedReferences: constraintType.References + }); + } else { + constraintType = { References: [], Text: "" }; + } + + // DefaultType + let defaultType: GeneratorHelpers.TypeToStringDto; + if (typeParameter.DefaultType != null) { + defaultType = GeneratorHelpers.TypeDtoToMarkdownString(typeParameter.DefaultType); + GeneratorHelpers.MergePluginResultData(pluginResult, { + UsedReferences: defaultType.References + }); + } else { + defaultType = { References: [], Text: "" }; + } + + return [ + typeParameter.Name, + constraintType.Text, + defaultType.Text + ]; + }); + + pluginResult.Result = new MarkdownBuilder() + .EmptyLine() + .Bold("Type parameters") + .EmptyLine() + .Table(header, content, GeneratorHelpers.DEFAULT_TABLE_OPTIONS) + .GetOutput(); + + return pluginResult; + } + + protected RenderType(type?: Contracts.TypeDto): PluginResultData | undefined { + if (type == null) { + return undefined; + } + const pluginResult = GeneratorHelpers.GetDefaultPluginResultData(); + + const parsedReturnType = GeneratorHelpers.TypeDtoToMarkdownString(type); + + pluginResult.Result = new MarkdownBuilder() + .EmptyLine() + .Bold("Type") + .EmptyLine() + .Text(parsedReturnType.Text) + .GetOutput(); + + pluginResult.UsedReferences = parsedReturnType.References; + return pluginResult; + } + + public abstract Render(data: PluginOptions): PluginResult; +} diff --git a/packages/ts-docs-gen/src/abstractions/container-plugin.ts b/packages/ts-docs-gen/src/abstractions/container-plugin.ts new file mode 100644 index 00000000..b4efafab --- /dev/null +++ b/packages/ts-docs-gen/src/abstractions/container-plugin.ts @@ -0,0 +1,115 @@ +import { Contracts, ExtractDto } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; +import { BasePlugin } from "./base-plugin"; +import { PluginOptions, PluginResultData } from "../contracts/plugin"; +import { GeneratorHelpers } from "../generator-helpers"; +import { ApiItemReference } from "../contracts/api-item-reference"; + +export interface ApiContainer extends Contracts.ApiBaseItemDto { + Members: Contracts.ApiItemReference[]; +} + +export interface ContainerMembersKindsGroup { + Heading: string; + Kinds: Contracts.ApiItemKinds[]; +} + +interface ContainerMembersReferencesGroup { + Heading: string; + References: ApiItemReference[]; +} + +export abstract class ContainerPlugin extends BasePlugin { + private getItemsReferenceByKind( + list: ContainerMembersKindsGroup[], + members: Contracts.ApiItemReference[], + extractedData: ExtractDto + ): ContainerMembersReferencesGroup[] { + const result: ContainerMembersReferencesGroup[] = []; + let membersReferences = GeneratorHelpers.GetApiItemReferences(extractedData, members); + + for (const item of list) { + // Filter item references by kind + const apiItemsReferenceByKind = membersReferences.filter(x => item.Kinds.indexOf(extractedData.Registry[x.Id].ApiKind) !== -1); + // Remove references that was used + membersReferences = membersReferences.filter(x => apiItemsReferenceByKind.indexOf(x) === -1); + + result.push({ + Heading: item.Heading, + References: apiItemsReferenceByKind + }); + } + + // TODO: Using ApiKind.Any to add everything to other if some kind is not supported. + if (membersReferences.length !== 0) { + result.push({ + Heading: "Other", + References: membersReferences + }); + } + + return result; + } + + protected RenderMembersGroups(list: ContainerMembersKindsGroup[], options: PluginOptions): PluginResultData { + const membersReferences = this.getItemsReferenceByKind(list, options.ApiItem.Members, options.ExtractedData); + const pluginResultData = GeneratorHelpers.GetDefaultPluginResultData(); + const builder = new MarkdownBuilder(); + + for (const { Heading, References } of membersReferences) { + if (References.length > 0) { + builder + .Header(Heading, 2) + .EmptyLine(); + + for (const reference of References) { + const apiItem = options.ExtractedData.Registry[reference.Id]; + + if (options.IsPluginResultExists(reference)) { + builder + .Text(md => md.Header(md.Link(apiItem.Name, reference.Id, true), 3)) + .EmptyLine(); + pluginResultData.UsedReferences.push(reference.Id); + } else { + switch (apiItem.ApiKind) { + case Contracts.ApiItemKinds.Namespace: + case Contracts.ApiItemKinds.Class: { + const renderedItem = options.GetItemPluginResult(reference); + pluginResultData.Members.push({ + Reference: reference, + PluginResult: renderedItem + }); + + builder + .Text(md => md.Header(md.Link(renderedItem.ApiItem.Name, reference.Id, true), 3)) + .EmptyLine(); + pluginResultData.UsedReferences.push(reference.Id); + break; + } + default: { + const renderedItem = options.GetItemPluginResult(reference); + builder + .Text(renderedItem.Result) + .EmptyLine(); + + GeneratorHelpers.MergePluginResultData(pluginResultData, { + Headings: renderedItem.Headings, + UsedReferences: renderedItem.UsedReferences + }); + } + } + } + + if ((References.indexOf(reference) + 1) !== References.length) { + builder + .HorizontalRule(undefined, 10) + .EmptyLine(); + } + } + } + } + + pluginResultData.Result = builder.GetOutput(); + return pluginResultData; + } +} diff --git a/packages/ts-docs-gen/src/abstractions/function-like-plugin.ts b/packages/ts-docs-gen/src/abstractions/function-like-plugin.ts new file mode 100644 index 00000000..0266acee --- /dev/null +++ b/packages/ts-docs-gen/src/abstractions/function-like-plugin.ts @@ -0,0 +1,55 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownGenerator, MarkdownBuilder } from "@simplrjs/markdown"; + +import { BasePlugin } from "./base-plugin"; +import { PluginResultData } from "../contracts/plugin"; +import { GeneratorHelpers } from "../generator-helpers"; + +export abstract class FunctionLikePlugin extends BasePlugin { + // TODO: Escape string! + protected RenderParameters(parameters: Contracts.ApiParameterDto[]): PluginResultData | undefined { + if (parameters.length === 0) { + return undefined; + } + + const pluginResult = GeneratorHelpers.GetDefaultPluginResultData(); + const header = ["Name", "Type", "Description"]; + + const content = parameters.map(parameter => { + const parameterTypeDto = GeneratorHelpers.TypeDtoToMarkdownString(parameter.Type); + GeneratorHelpers.MergePluginResultData(pluginResult, { + UsedReferences: parameterTypeDto.References + }); + + return [parameter.Name, MarkdownGenerator.EscapeString(parameterTypeDto.Text), parameter.Metadata.DocumentationComment]; + }); + + pluginResult.Result = new MarkdownBuilder() + .EmptyLine() + .Bold("Parameters") + .EmptyLine() + .Table(header, content, GeneratorHelpers.DEFAULT_TABLE_OPTIONS) + .GetOutput(); + + return pluginResult; + } + + protected RenderReturnType(type?: Contracts.TypeDto): PluginResultData | undefined { + if (type == null) { + return undefined; + } + const pluginResult = GeneratorHelpers.GetDefaultPluginResultData(); + + const parsedReturnType = GeneratorHelpers.TypeDtoToMarkdownString(type); + + pluginResult.Result = new MarkdownBuilder() + .EmptyLine() + .Bold("Return type") + .EmptyLine() + .Text(parsedReturnType.Text) + .GetOutput(); + + pluginResult.UsedReferences = parsedReturnType.References; + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/builders/generator-configuration-builder.ts b/packages/ts-docs-gen/src/builders/generator-configuration-builder.ts new file mode 100644 index 00000000..f92bbeea --- /dev/null +++ b/packages/ts-docs-gen/src/builders/generator-configuration-builder.ts @@ -0,0 +1,91 @@ +import * as ts from "typescript"; +import * as path from "path"; +import { Extractor, GetCompilerOptions } from "ts-extractor"; + +import { GeneratorConfiguration, WorkingGeneratorConfiguration } from "../contracts/generator-configuration"; +import { Plugin } from "../contracts/plugin"; + +import { PluginRegistry } from "../registries/plugin-registry"; +import { DefaultPlugins } from "../default-plugins"; + +// TODO: Add method to read compiler options from tsconfig. +export class GeneratorConfigurationBuilder { + constructor(private projectDirectory: string) { } + + private configuration: Partial = {}; + private compilerOptions: Partial; + + public OverrideCompilerOptions(compilerOptions: Partial): this { + this.compilerOptions = { + ...this.compilerOptions, + ...compilerOptions + }; + + return this; + } + + /** + * Override configuration with new configuration object. + * + * @param configuration Partial configuration object. + */ + public OverrideConfiguration(configuration: Partial): this { + this.configuration = { + ...this.configuration, + ...configuration + }; + + return this; + } + + public SetOutputDirectory(outputDirectory: string): this { + this.configuration.OutputDirectory = outputDirectory; + + return this; + } + + public AddPlugins(plugins: Plugin[]): this { + const currentPlugins = this.configuration.Plugins || []; + this.configuration.Plugins = [...plugins, ...currentPlugins]; + + return this; + } + + public async Build(entryFiles: string[]): Promise { + // Register all plugins. + const pluginManager = new PluginRegistry(); + // Register default plugins + for (const item of DefaultPlugins) { + pluginManager.Register(item); + } + + if (this.configuration.Plugins != null) { + // TODO: Register default plugins. + // Registering given plugins. + for (const plugin of this.configuration.Plugins) { + pluginManager.Register(plugin); + } + + } + + // Resolve tsconfig + let compilerOptions = this.compilerOptions; + if (compilerOptions == null) { + compilerOptions = await GetCompilerOptions(path.join(this.projectDirectory, "tsconfig.json")); + } + + // Extractor + const extractor = new Extractor({ + CompilerOptions: compilerOptions, + ProjectDirectory: this.projectDirectory + }); + + const outputDirectory = this.configuration.OutputDirectory || path.join(this.projectDirectory, "/docs/"); + + return { + PluginManager: pluginManager, + ExtractedData: extractor.Extract(entryFiles), + OutputDirectory: outputDirectory + }; + } +} diff --git a/packages/ts-docs-gen/src/contracts/api-item-reference.ts b/packages/ts-docs-gen/src/contracts/api-item-reference.ts new file mode 100644 index 00000000..628a8231 --- /dev/null +++ b/packages/ts-docs-gen/src/contracts/api-item-reference.ts @@ -0,0 +1,4 @@ +export interface ApiItemReference { + Id: string; + Alias: string; +} diff --git a/packages/ts-docs-gen/src/contracts/file-result.ts b/packages/ts-docs-gen/src/contracts/file-result.ts new file mode 100644 index 00000000..a89583f4 --- /dev/null +++ b/packages/ts-docs-gen/src/contracts/file-result.ts @@ -0,0 +1,4 @@ +export interface FileResult { + FileLocation: string; + Result: string[]; +} diff --git a/packages/ts-docs-gen/src/contracts/generator-configuration.ts b/packages/ts-docs-gen/src/contracts/generator-configuration.ts new file mode 100644 index 00000000..e6a8a665 --- /dev/null +++ b/packages/ts-docs-gen/src/contracts/generator-configuration.ts @@ -0,0 +1,19 @@ +import { ExtractDto } from "ts-extractor"; + +import { PluginRegistry } from "../registries/plugin-registry"; +import { Plugin } from "./plugin"; + +export interface GeneratorConfiguration { + OutputDirectory: string; + PluginManager: PluginRegistry; + ExtractedData: ExtractDto; +} + +export interface WorkingGeneratorConfiguration { + OutputDirectory: string; + ProjectDirectory: string; + Plugins: Plugin[]; + + Exclude: string[]; + OutputPathSeparator: string; +} diff --git a/packages/ts-docs-gen/src/contracts/plugin-result-registry.ts b/packages/ts-docs-gen/src/contracts/plugin-result-registry.ts new file mode 100644 index 00000000..3a956da9 --- /dev/null +++ b/packages/ts-docs-gen/src/contracts/plugin-result-registry.ts @@ -0,0 +1,11 @@ +import { PluginResult } from "./plugin"; +import { ApiItemReference } from "./api-item-reference"; + +export interface ReadonlyPluginResultRegistry { + GetItem(itemReference: ApiItemReference): PluginResult | undefined; + Exists(itemReference: ApiItemReference): boolean; +} + +export interface PluginResultRegistry extends ReadonlyPluginResultRegistry { + AddItem(itemReference: ApiItemReference, pluginResult: PluginResult): void; +} diff --git a/packages/ts-docs-gen/src/contracts/plugin.ts b/packages/ts-docs-gen/src/contracts/plugin.ts new file mode 100644 index 00000000..1b6b4df3 --- /dev/null +++ b/packages/ts-docs-gen/src/contracts/plugin.ts @@ -0,0 +1,57 @@ +import { Contracts, ExtractDto } from "ts-extractor"; + +import { ApiItemReference } from "./api-item-reference"; + +export enum ApiItemKindsAdditional { + Any = "any" +} + +export type SupportedApiItemKindType = Contracts.ApiItemKinds | ApiItemKindsAdditional; + +export interface PluginHeading { + Heading: string; + ApiItemId: string; +} + +export interface PluginMember { + Reference: ApiItemReference; + PluginResult: PluginResult; +} + +export type GetItemPluginResultHandler = (reference: ApiItemReference) => PluginResult; +export type IsPluginResultExistsHandler = (reference: ApiItemReference) => boolean; + +export interface PluginOptions { + Reference: ApiItemReference; + ApiItem: TKind; + ExtractedData: ExtractDto; + GetItemPluginResult: GetItemPluginResultHandler; + IsPluginResultExists: IsPluginResultExistsHandler; +} + +export interface PluginResultData { + /** + * All headings used in `Result` with ApiItemIds. + */ + Headings: PluginHeading[]; + /** + * References that were used in rendering `Result`. + */ + UsedReferences: string[]; + /** + * Plugin rendered result. + */ + Result: string[]; + Members: PluginMember[]; +} + +export interface PluginResult extends PluginResultData { + Reference: ApiItemReference; + ApiItem: TKind; +} + +export interface Plugin { + SupportedApiItemKinds(): SupportedApiItemKindType[]; + CheckApiItem(item: TKind): boolean; + Render(options: PluginOptions): PluginResult; +} diff --git a/packages/ts-docs-gen/src/debug.ts b/packages/ts-docs-gen/src/debug.ts new file mode 100644 index 00000000..147abc82 --- /dev/null +++ b/packages/ts-docs-gen/src/debug.ts @@ -0,0 +1,22 @@ +// This is debug file. DO NOT include in compiled package. +import * as path from "path"; + +import { GeneratorConfigurationBuilder } from "./builders/generator-configuration-builder"; +import { Generator } from "./generator"; + +async function Main(): Promise { + const projectDirectory = path.join(process.cwd(), "./examples/simple/"); + // const entryFiles = ["./index.ts", "./exported-const-variables.ts", "./exported-functions.ts"]; + const entryFiles = ["./exported-functions.ts", "./index.ts"]; + + const configPromise = new GeneratorConfigurationBuilder(projectDirectory).Build(entryFiles); + const config = await configPromise; + + const generator = new Generator(config); + // tslint:disable-next-line:no-console + console.log(generator.OutputData); + // tslint:disable-next-line:no-debugger + await generator.WriteToFiles(); +} + +Main(); diff --git a/packages/ts-docs-gen/src/default-plugins.ts b/packages/ts-docs-gen/src/default-plugins.ts new file mode 100644 index 00000000..4e17f40b --- /dev/null +++ b/packages/ts-docs-gen/src/default-plugins.ts @@ -0,0 +1,31 @@ +import { ApiSourceFilePlugin } from "./plugins/api-source-file-plugin"; +import { ApiVariablePlugin } from "./plugins/api-variable-plugin"; +import { ApiEnumPlugin } from "./plugins/api-enum-plugin"; +import { ApiFunctionPlugin } from "./plugins/api-function-plugin"; +import { ApiTypePlugin } from "./plugins/api-type-plugin"; +import { ApiNamespacePlugin } from "./plugins/api-namespace-plugin"; +import { ApiInterfacePlugin } from "./plugins/api-interface-plugin"; +import { ApiCallablePlugin } from "./plugins/api-callable-plugin"; +import { ApiIndexPlugin } from "./plugins/api-index-plugin"; +import { ApiClassPlugin } from "./plugins/api-class-plugin"; +import { ApiClassConstructorPlugin } from "./plugins/api-class-constructor-plugin"; +import { ApiClassMethodPlugin } from "./plugins/api-class-method-plugin"; +import { ApiClassPropertyPlugin } from "./plugins/api-class-property-plugin"; +import { ApiClassAccessorPlugin } from "./plugins/api-class-accessor-plugin"; + +export const DefaultPlugins = [ + new ApiSourceFilePlugin(), + new ApiVariablePlugin(), + new ApiEnumPlugin(), + new ApiFunctionPlugin(), + new ApiTypePlugin(), + new ApiNamespacePlugin(), + new ApiInterfacePlugin(), + new ApiCallablePlugin(), + new ApiIndexPlugin(), + new ApiClassPlugin(), + new ApiClassConstructorPlugin(), + new ApiClassMethodPlugin(), + new ApiClassPropertyPlugin(), + new ApiClassAccessorPlugin() +]; diff --git a/packages/ts-docs-gen/src/file-manager.ts b/packages/ts-docs-gen/src/file-manager.ts new file mode 100644 index 00000000..60214a1c --- /dev/null +++ b/packages/ts-docs-gen/src/file-manager.ts @@ -0,0 +1,99 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownGenerator } from "@simplrjs/markdown"; +import * as path from "path"; + +import { Helpers } from "./utils/helpers"; +import { PluginResult } from "./contracts/plugin"; +import { FileResult } from "./contracts/file-result"; +import { GeneratorHelpers } from "./generator-helpers"; + +interface OutputData { + Result: string[]; + UsedReferences: string[]; +} + +type RenderedItemList = Array; + +// TODO: remove unused files before generating docs. +export class FileManager { + /** + * + */ + private filesList: Map = new Map(); + /** + * + */ + private referenceToFile: Map = new Map(); + + public AddEntryFile(itemResult: PluginResult): void { + const filePath = path.basename( + itemResult.ApiItem.Location.FileName, + path.extname(itemResult.ApiItem.Location.FileName + ) + ) + GeneratorHelpers.MARKDOWN_EXT; + + this.AddItem(itemResult, filePath); + } + + public AddItem(itemResult: PluginResult, filePath: string): void { + const items = this.filesList.get(filePath) || []; + items.push(itemResult); + this.filesList.set(filePath, items); + // Adding headings. + for (const heading of itemResult.Headings) { + this.referenceToFile.set(heading.ApiItemId, `${filePath}#${Helpers.HeadingToAnchor(heading.Heading)}`); + } + + // HeadingsMap + if (itemResult.Members != null) { + for (const member of itemResult.Members) { + const baseName = path.basename(filePath, path.extname(filePath)); + const targetFilePath = path.join( + path.dirname(filePath), + baseName, + member.PluginResult.ApiItem.Name + GeneratorHelpers.MARKDOWN_EXT + ).toLowerCase(); + + this.AddItem(member.PluginResult, targetFilePath); + } + } + } + + public ToFilesOutput(): FileResult[] { + const files: FileResult[] = []; + + for (const [fileLocation, items] of this.filesList) { + // Link definitions to file location. + const linkDefinitions: string[] = []; + for (const item of items.reverse()) { + item.UsedReferences + .forEach(referenceId => { + const filePath = path.dirname(fileLocation); + + const referenceString = this.referenceToFile.get(referenceId); + const resolvePath = GeneratorHelpers.StandardisePath(path.relative(filePath, referenceString || "#__error")); + + linkDefinitions.push( + MarkdownGenerator.LinkDefinition(referenceId, resolvePath) + ); + + if (!referenceString) { + console.warn(`Reference "${referenceId}" not found. Check ${fileLocation}.`); + } + }); + } + + const itemsResult = Helpers.Flatten(items.map(x => [x.Result, ""])); + + files.push({ + FileLocation: GeneratorHelpers.StandardisePath(fileLocation), + Result: [ + ...linkDefinitions, + ...itemsResult + ] + }); + } + + return files; + } +} diff --git a/packages/ts-docs-gen/src/generator-helpers.ts b/packages/ts-docs-gen/src/generator-helpers.ts new file mode 100644 index 00000000..562fed93 --- /dev/null +++ b/packages/ts-docs-gen/src/generator-helpers.ts @@ -0,0 +1,751 @@ +import { Contracts, ExtractDto, TSHelpers } from "ts-extractor"; +import { LogLevel } from "simplr-logger"; +import { MarkdownGenerator, MarkdownBuilder, Contracts as MarkdownContracts } from "@simplrjs/markdown"; +import * as path from "path"; + +import { ApiItemReference } from "./contracts/api-item-reference"; +import { ApiItemKindsAdditional, PluginResultData } from "./contracts/plugin"; +import { Logger } from "./utils/logger"; +import { Helpers } from "./utils/helpers"; + +export namespace GeneratorHelpers { + export type TypeToStringDto = ReferenceDto; + + export interface ReferenceDto { + References: string[]; + Text: T; + } + + export enum JSDocTags { + Beta = "beta", + Deprecated = "deprecated", + Internal = "internal", + Summary = "summary" + } + + // #region Defaults and constants + + export const MARKDOWN_EXT = ".md"; + + export const ApiItemKinds: typeof ApiItemKindsAdditional & typeof Contracts.ApiItemKinds = + Object.assign(ApiItemKindsAdditional, Contracts.ApiItemKinds); + + export const DEFAULT_CODE_OPTIONS = { + lang: "typescript" + }; + + export const DEFAULT_TABLE_OPTIONS: MarkdownContracts.TableOptions = { + removeColumnIfEmpty: true, + removeRowIfEmpty: true + }; + + // #endregion Defaults and constants + + // #region General helpers + + export function GetApiItemKinds(): typeof Contracts.ApiItemKinds & typeof ApiItemKindsAdditional { + return Object.assign(Contracts.ApiItemKinds, ApiItemKindsAdditional); + } + + export function GetApiItemReferences( + extractedData: ExtractDto, + itemsReference: Contracts.ApiItemReference[] + ): ApiItemReference[] { + let overallReferences: ApiItemReference[] = []; + + for (const item of itemsReference) { + for (const referenceId of item.Ids) { + // Check if item is ExportSpecifier or ExportDeclaration. + const apiItem = extractedData.Registry[referenceId]; + + switch (apiItem.ApiKind) { + case Contracts.ApiItemKinds.Export: { + if (apiItem.SourceFileId != null) { + const sourceFileReference = { Alias: apiItem.Name, Ids: [apiItem.SourceFileId] }; + const referencesList = GetApiItemReferences(extractedData, [sourceFileReference]); + overallReferences = overallReferences.concat(referencesList); + } + break; + } + case Contracts.ApiItemKinds.ImportSpecifier: + case Contracts.ApiItemKinds.ExportSpecifier: { + if (apiItem.ApiItems == null) { + LogWithApiItemPosition( + LogLevel.Warning, + apiItem, + `ApiItems are missing in "${apiItem.Name}"?` + ); + break; + } + + const apiItemReference = { Alias: apiItem.Name, Ids: apiItem.ApiItems }; + const referencesList = GetApiItemReferences(extractedData, [apiItemReference]); + overallReferences = overallReferences.concat(referencesList); + break; + } + case Contracts.ApiItemKinds.SourceFile: { + if (apiItem.Members == null) { + LogWithApiItemPosition( + LogLevel.Warning, + apiItem, + "Members are missing" + ); + } + + const referencesList = GetApiItemReferences(extractedData, apiItem.Members); + overallReferences = overallReferences.concat(referencesList); + break; + } + default: { + overallReferences.push({ + Id: referenceId, + Alias: item.Alias + }); + } + } + } + } + + return overallReferences; + } + + export function GetApiItemsFromReference( + items: Contracts.ApiItemReference[], + extractedData: ExtractDto, + apiItemKind?: Contracts.ApiItemKinds + ): T[] { + const apiItems: T[] = []; + + for (const itemReferences of items) { + for (const referenceId of itemReferences.Ids) { + const apiItem = extractedData.Registry[referenceId] as T; + if (apiItemKind == null || apiItemKind != null && apiItem.ApiKind === apiItemKind) { + apiItems.push(apiItem); + } + } + } + + return apiItems; + } + + export function LogWithApiItemPosition(logLevel: LogLevel, apiItem: Contracts.ApiItemDto, message: string): void { + const { FileName, Line, Character } = apiItem.Location; + const linePrefix = `${FileName}[${Line}:${Character + 1}]`; + Logger.Log(logLevel, `${linePrefix}: ${message}`); + } + + export function StandardisePath(pathString: string): string { + return pathString.split(path.sep).join("/"); + } + + export function IsApiItemKind( + itemKind: Contracts.ApiItemKinds, + apiItem: Contracts.ApiItemDto): apiItem is TKindDto { + return apiItem.ApiKind === itemKind; + } + + export function MergePluginResultData(a: T, b: Partial | undefined): T { + if (b == null) { + return a; + } + + a.Headings = a.Headings.concat(b.Headings || []); + a.Members = (a.Members || []).concat(b.Members || []); + a.Result = a.Result.concat(b.Result || []); + a.UsedReferences = a.UsedReferences.concat(b.UsedReferences || []); + + return a; + } + + export function GetDefaultPluginResultData(): PluginResultData { + return { + Headings: [], + Result: [], + UsedReferences: [], + Members: [] + }; + } + // #endregion General helpers + + // #region Render helpers + + // TODO: implement type literal and function type. + export function TypeDtoToMarkdownString(type: Contracts.TypeDto): TypeToStringDto { + let references: string[] = []; + let text: string = ""; + + switch (type.ApiTypeKind) { + case Contracts.TypeKinds.Union: + case Contracts.TypeKinds.Intersection: { + const symbol = type.ApiTypeKind === Contracts.TypeKinds.Union ? "|" : "&"; + + if (type.ReferenceId != null) { + text = MarkdownGenerator.Link(type.Name || type.Text, type.ReferenceId, true); + references.push(type.ReferenceId); + break; + } + + type.Types + .map(TypeDtoToMarkdownString) + .forEach(typeItem => { + references = references.concat(typeItem.References); + + if (text === "") { + text = typeItem.Text; + } else { + text += ` ${symbol} ${typeItem.Text}`; + } + }); + break; + } + case Contracts.TypeKinds.Basic: + default: { + // Basic type with reference. + if (type.Name == null || TSHelpers.IsInternalSymbolName(type.Name)) { + text = type.Text; + } else { + // FIXME: do not use flag string. Exclude Type parameters references. + if (type.ReferenceId != null && type.FlagsString !== "TypeParameter") { + text = MarkdownGenerator.Link(type.Name || type.Text, type.ReferenceId, true); + references.push(type.ReferenceId); + } else { + text = type.Name; + } + } + + // Generics + if (type.Name != null && type.Generics != null) { + const generics = type.Generics.map(TypeDtoToMarkdownString); + references = references.concat(...generics.map(x => x.References)); + + text += MarkdownGenerator.EscapeString(`<${generics.map(x => x.Text).join(", ")}>`); + } + } + } + + return { + References: references, + Text: text + }; + } + + export function RenderApiItemMetadata(apiItem: Contracts.ApiItemDto): string[] { + const builder = new MarkdownBuilder(); + + // Optimise? + const isBeta = apiItem.Metadata.JSDocTags.findIndex(x => x.name.toLowerCase() === JSDocTags.Beta) !== -1; + const deprecated = apiItem.Metadata.JSDocTags.find(x => x.name.toLowerCase() === JSDocTags.Deprecated); + const internal = apiItem.Metadata.JSDocTags.find(x => x.name.toLowerCase() === JSDocTags.Internal); + const summary = apiItem.Metadata.JSDocTags.find(x => x.name.toLowerCase() === JSDocTags.Summary); + const jSDocComment = apiItem.Metadata.DocumentationComment; + + if (isBeta) { + builder + .Text(`Warning: Beta!`) + .EmptyLine(); + } + + if (deprecated != null) { + const message = Boolean(deprecated.text) ? `: ${deprecated.text}` : ""; + builder + .Text(`Deprecated${message}!`) + .EmptyLine(); + } + + if (internal != null) { + const message = Boolean(internal.text) ? `: ${internal.text}` : ""; + builder + .Bold(`Internal${message}`) + .EmptyLine(); + } + + if (jSDocComment.length > 0) { + builder + .Text(jSDocComment) + .EmptyLine(); + } + + if (summary != null && Boolean(summary.text)) { + builder + .Blockquote(summary.text!.split("\n")) + .EmptyLine(); + } + + return builder.GetOutput(); + } + + const TAB_STRING = " "; + + export function Tab(size: number = 1): string { + let result: string = ""; + for (let i = 0; i < size; i++) { + result += TAB_STRING; + } + return result; + } + + export function FixSentence(sentence: string, punctuationMark: string = "."): string { + const trimmedSentence = sentence.trim(); + const punctuationMarks = ".!:;,-"; + + const lastSymbol = trimmedSentence[trimmedSentence.length - 1]; + + if (punctuationMarks.indexOf(lastSymbol) !== -1) { + return trimmedSentence; + } + + return trimmedSentence + punctuationMark; + } + + // #endregion Render helpers + + // #region Stringifiers + + // TODO: optimize. + export function ApiInterfaceToString( + apiItem: Contracts.ApiInterfaceDto, + extractedData: ExtractDto + ): string[] { + const typeParameters = GetApiItemsFromReference(apiItem.TypeParameters, extractedData); + const typeParametersString = TypeParametersToString(typeParameters); + + let extendsString: string; + + if (apiItem.Extends.length === 0) { + extendsString = ""; + } else { + const typesExtended = apiItem.Extends + .map(x => x.Text) + .join(", "); + extendsString = ` extends ${typesExtended}`; + } + + const builder = new MarkdownBuilder() + .Text(`interface ${apiItem.Name}${typeParametersString}${extendsString} {`); + + const constructMembers = GetApiItemsFromReference( + apiItem.Members, + extractedData, + Contracts.ApiItemKinds.Construct + ); + constructMembers.forEach(member => { + const parameters = GetApiItemsFromReference(member.Parameters, extractedData); + const memberTypeParameters = GetApiItemsFromReference(member.TypeParameters, extractedData); + builder.Text(`${Tab(1)}${ApiConstructToString(memberTypeParameters, parameters, member.ReturnType)};`); + }); + + const callMembers = GetApiItemsFromReference( + apiItem.Members, + extractedData, + Contracts.ApiItemKinds.Call + ); + callMembers.forEach(member => { + const parameters = GetApiItemsFromReference(member.Parameters, extractedData); + const memberTypeParameters = GetApiItemsFromReference(member.TypeParameters, extractedData); + builder.Text(`${Tab(1)}${ApiCallToString(memberTypeParameters, parameters, member.ReturnType)};`); + }); + + const indexMembers = GetApiItemsFromReference( + apiItem.Members, + extractedData, + Contracts.ApiItemKinds.Index + ); + indexMembers.forEach(member => { + const parameter = extractedData.Registry[member.Parameter] as Contracts.ApiParameterDto; + builder.Text(`${Tab(1)}${ApiIndexToString(parameter, member.Type, member.IsReadonly)};`); + }); + + const methodMembers = GetApiItemsFromReference( + apiItem.Members, + extractedData, + Contracts.ApiItemKinds.Method + ); + methodMembers.forEach(member => { + const parameters = GetApiItemsFromReference(member.Parameters, extractedData); + const memberTypeParameters = GetApiItemsFromReference(member.TypeParameters, extractedData); + + builder.Text(`${Tab(1)}${ApiMethodToString(member.Name, memberTypeParameters, parameters, member.ReturnType)};`); + }); + + const propertyMembers = GetApiItemsFromReference( + apiItem.Members, + extractedData, + Contracts.ApiItemKinds.Property + ); + propertyMembers.forEach(member => { + builder.Text(`${Tab(1)}${ApiPropertyToString(member)};`); + }); + + builder.Text("}"); + + return builder.GetOutput(); + } + + export function ApiTypeToString(item: Contracts.ApiTypeDto, alias?: string): string { + const name = alias != null ? alias : item.Name; + + return `type ${name} = ${item.Type.Text};`; + } + + export function ApiInterfaceToSimpleString(alias: string, apiItem: Contracts.ApiInterfaceDto): string { + const name = alias || apiItem.Name; + return `interface ${name}`; + } + + export function ApiIndexToString(parameter: Contracts.ApiParameterDto, type: Contracts.TypeDto, readOnly: boolean = false): string { + const typeString = TypeDtoToMarkdownString(type).Text; + const parameterTypeString = TypeDtoToMarkdownString(parameter.Type).Text; + + const readOnlyString = readOnly ? "readonly " : ""; + + return `${readOnlyString}[${parameter.Name}: ${parameterTypeString}]: ${typeString}`; + } + + export function ApiPropertyToString(apiItem: Contracts.ApiPropertyDto): string { + const optional = apiItem.IsOptional ? "?" : ""; + const readOnly = apiItem.IsReadonly ? "readonly " : ""; + + return `${readOnly}${apiItem.Name}${optional}: ${apiItem.Type.Text}`; + } + + export function ApiAccessorToString( + apiItem: Contracts.ApiGetAccessorDto | Contracts.ApiSetAccessorDto, + type: Contracts.TypeDto | undefined, + alias?: string + ): string { + const name = alias || apiItem.Name; + const abstract = apiItem.IsAbstract ? " abstract" : ""; + const $static = apiItem.IsStatic ? " static" : ""; + + const typeString = type != null ? type.Text : "???"; + let accessorType: string; + if (apiItem.ApiKind === Contracts.ApiItemKinds.SetAccessor) { + accessorType = "set"; + } else { + accessorType = "get"; + } + + return `${apiItem.AccessModifier}${$static}${abstract} ${accessorType} ${name}: ${typeString};`; + } + + export function ApiClassPropertyToString(apiItem: Contracts.ApiClassPropertyDto, alias?: string): string { + const name = alias || apiItem.Name; + + const optional = apiItem.IsOptional ? "?" : ""; + const readOnly = apiItem.IsReadonly ? " readonly" : ""; + const abstract = apiItem.IsAbstract ? " abstract" : ""; + const $static = apiItem.IsStatic ? " static" : ""; + + return `${apiItem.AccessModifier}${$static}${abstract}${readOnly} ${name}${optional}: ${apiItem.Type.Text};`; + } + + export function ApiEnumToString(apiItem: Contracts.ApiEnumDto, memberItems: Contracts.ApiEnumMemberDto[], alias?: string): string[] { + const name = alias || apiItem.Name; + const $const = apiItem.IsConst ? "const " : ""; + + // Constructing enum body. + const membersStrings = memberItems.map((memberItem, index, array) => { + // Add an enum name + let memberString = `${GeneratorHelpers.Tab()} ${memberItem.Name}`; + + // Add an enum member value if it exists. + if (memberItem.Value) { + memberString += ` = ${memberItem.Value}`; + } + + // Add a comma if current item is not the last item + if (index !== memberItems.length - 1) { + memberString += ","; + } + + return memberString; + }); + + // Construct enum code output + return [ + `${$const}enum ${name} {`, + ...membersStrings, + "}" + ]; + } + + export function ApiVariableToString(item: Contracts.ApiVariableDto, alias?: string): string { + const name = alias != null ? alias : item.Name; + + return `${item.VariableDeclarationType} ${name}: ${item.Type.Text};`; + } + + export function ClassToString( + apiItem: Contracts.ApiClassDto, + typeParameters?: Contracts.ApiTypeParameterDto[], + alias?: string + ): string { + const name = alias || apiItem.Name; + // Abstract + const abstract = apiItem.IsAbstract ? "abstract " : ""; + + // TypeParameters + const typeParametersString: string = TypeParametersToString(typeParameters); + + // Extends + let extendsString: string; + if (apiItem.Extends != null) { + extendsString = ` extends ${apiItem.Extends.Text}`; + } else { + extendsString = ""; + } + + // Implements + let implementsString: string; + if (apiItem.Implements != null && apiItem.Implements.length > 0) { + implementsString = ` implements ${apiItem.Implements.map(x => x.Text).join(", ")}`; + } else { + implementsString = ""; + } + + return `${abstract}class ${name}${typeParametersString}${extendsString}${implementsString}`; + } + + export function TypeParametersToString(typeParameters?: Contracts.ApiTypeParameterDto[]): string { + if (typeParameters != null && typeParameters.length > 0) { + const params: string[] = typeParameters.map(TypeParameterToString); + return `<${params.join(", ")}>`; + } else { + return ""; + } + } + + export function TypeParameterToString(apiItem: Contracts.ApiTypeParameterDto): string { + const extendsString = apiItem.ConstraintType != null ? ` extends ${apiItem.ConstraintType.Text}` : ""; + const defaultType = apiItem.DefaultType != null ? ` = ${apiItem.DefaultType.Text}` : ""; + + return `${apiItem.Name}${extendsString}${defaultType}`; + } + + // #endregion Stringifiers + + // #region Tables + export function ApiPropertiesToTableString(properties: Contracts.ApiPropertyDto[]): ReferenceDto { + const headers = ["Name", "Type", "Optional"]; + return ApiItemsToTableString(headers, properties, ApiPropertyToTableRow); + } + + export function ApiPropertyToTableRow(property: Contracts.ApiPropertyDto): ReferenceDto { + const parameterTypeDto = TypeDtoToMarkdownString(property.Type); + const isOptionalString = property.IsOptional ? "Yes" : ""; + + return { + Text: [property.Name, parameterTypeDto.Text, isOptionalString], + References: parameterTypeDto.References + }; + } + + export function ApiParametersToTableString(parameters: Contracts.ApiParameterDto[]): ReferenceDto { + const headers = ["Name", "Type", "Optional", "Initial value", "Description"]; + return ApiItemsToTableString(headers, parameters, ApiParameterToTableRow); + } + + // TODO: implement description. + // TODO: implement IsSpread. + export function ApiParameterToTableRow(parameter: Contracts.ApiParameterDto): ReferenceDto { + const parameterTypeDto = TypeDtoToMarkdownString(parameter.Type); + const isOptionalString = parameter.IsOptional ? "Yes" : ""; + const initializerString = parameter.Initializer || ""; + + return { + Text: [parameter.Name, MarkdownGenerator.EscapeString(parameterTypeDto.Text), isOptionalString, initializerString], + References: parameterTypeDto.References + }; + } + + export function ApiTypeParametersTableToString(typeParameters: Contracts.ApiTypeParameterDto[]): ReferenceDto { + const headers = ["Name", "Constraint type", "Default type"]; + return ApiItemsToTableString(headers, typeParameters, ApiTypeParameterToTableRow); + } + + // TODO: add description from @template jsdoc tag. + export function ApiTypeParameterToTableRow(typeParameter: Contracts.ApiTypeParameterDto): ReferenceDto { + let referenceIds: string[] = []; + let constraintType: string = ""; + let defaultType: string = ""; + + if (typeParameter.ConstraintType) { + const parsedConstraintType = TypeDtoToMarkdownString(typeParameter.ConstraintType); + + referenceIds = referenceIds.concat(parsedConstraintType.References); + constraintType = MarkdownGenerator.EscapeString(parsedConstraintType.Text); + } + + if (typeParameter.DefaultType) { + const parsedDefaultType = TypeDtoToMarkdownString(typeParameter.DefaultType); + + referenceIds = referenceIds.concat(parsedDefaultType.References); + defaultType = MarkdownGenerator.EscapeString(parsedDefaultType.Text); + } + + return { + Text: [typeParameter.Name, constraintType, defaultType], + References: referenceIds + }; + } + + export function ApiItemsToTableString( + headers: string[], + items: TApiDto[], + itemToString: (item: TApiDto) => ReferenceDto + ): ReferenceDto { + if (items.length === 0) { + return { + References: [], + Text: [] + }; + } + + const rows = items.map(itemToString); + const content = rows.map(row => row.Text); + const referenceIds = Helpers.Flatten(rows.map(row => row.References)); + + return { + Text: MarkdownGenerator.Table(headers, content, DEFAULT_TABLE_OPTIONS), + References: referenceIds + }; + } + + //#endregion Tables + + // #region Call strings + /** + * Builds call declaration. + * + * Return example: `(arg: TValue): void`. + */ + export function ApiCallToString( + typeParameters?: Contracts.ApiTypeParameterDto[], + parameters?: Contracts.ApiParameterDto[], + returnType?: Contracts.TypeDto + ): string { + // TypeParameters + const typeParametersString = TypeParametersToString(typeParameters); + + // Parameters + let parametersString: string; + if (parameters != null && parameters.length > 0) { + parametersString = parameters + .map(ApiParameterToString) + .join(", "); + } else { + parametersString = ""; + } + + // ReturnType + const returnTypeString = returnType != null ? `: ${returnType.Text}` : ""; + + return `${typeParametersString}(${parametersString})${returnTypeString}`; + } + + /** + * Builds ApiParameter string. + * + * Return example: `arg: TValue`. + */ + export function ApiParameterToString(apiItem: Contracts.ApiParameterDto): string { + // FIXME: `?` and `| undefined` in a single statement. + const initializerString = apiItem.Initializer ? ` = ${apiItem.Initializer}` : ""; + const isOptionalString = apiItem.IsOptional ? "?" : ""; + return `${apiItem.Name}${isOptionalString}: ${apiItem.Type.Text}${initializerString}`; + } + + export function ApiClassConstructorToString( + apiItem: Contracts.ApiClassConstructorDto, + parameters?: Contracts.ApiParameterDto[], + returnType?: Contracts.TypeDto + ): string { + const callString = ApiCallToString(undefined, parameters, returnType); + return `${apiItem.AccessModifier} constructor${callString}`; + } + + /** + * Builds function head from ApiFunction. + * + * Return example: `function foo(arg: TValue): void`. + */ + export function ApiFunctionToString( + apiItem: Contracts.ApiFunctionDto, + typeParameters?: Contracts.ApiTypeParameterDto[], + parameters?: Contracts.ApiParameterDto[], + alias?: string + ): string { + const name = alias || apiItem.Name; + const callString = ApiCallToString(typeParameters, parameters, apiItem.ReturnType); + + return `function ${name}${callString}`; + } + + /** + * Builds construct declaration. + * + * Return example: `new (arg: TValue): void`. + */ + export function ApiConstructToString( + typeParameters?: Contracts.ApiTypeParameterDto[], + parameters?: Contracts.ApiParameterDto[], + returnType?: Contracts.TypeDto + ): string { + const callString = ApiCallToString(typeParameters, parameters, returnType); + + return `new ${callString}`; + } + + /** + * Builds method declaration. + * + * Return example: `someMethod(arg: TValue): void`. + */ + export function ApiMethodToString( + name: string, + typeParameters?: Contracts.ApiTypeParameterDto[], + parameters?: Contracts.ApiParameterDto[], + returnType?: Contracts.TypeDto + ): string { + const callString = ApiCallToString(typeParameters, parameters, returnType); + + return `${name}${callString}`; + } + + /** + * Builds class method declaration. + * + * Return example: `public static SomeMethod(arg: TValue): void`. + */ + export function ApiClassMethodToString( + apiItem: Contracts.ApiClassMethodDto, + typeParameters: Contracts.ApiTypeParameterDto[], + parameters: Contracts.ApiParameterDto[], + alias?: string + ): string { + const name = alias || apiItem.Name; + + const optional = apiItem.IsOptional ? "?" : ""; + const abstract = apiItem.IsAbstract ? " abstract" : ""; + const async = apiItem.IsAsync ? " async" : ""; + const $static = apiItem.IsStatic ? " static" : ""; + const functionHeader = ApiMethodToString(`${name}${optional}`, typeParameters, parameters, apiItem.ReturnType); + + return `${apiItem.AccessModifier}${$static}${abstract}${async} ${functionHeader}`.trim(); + } + + /** + * Build simplified method declaration + * + * Return example: `someMethod(parameter1, parameter2)`. + */ + export function MethodToSimpleString(text: string, parameters: Contracts.ApiParameterDto[]): string { + const parametersString = parameters + .map(x => x.Name) + .join(", "); + + return `${text}(${parametersString})`; + } + + // #endregion Call strings +} diff --git a/packages/ts-docs-gen/src/generator.ts b/packages/ts-docs-gen/src/generator.ts new file mode 100644 index 00000000..ae8bcfbe --- /dev/null +++ b/packages/ts-docs-gen/src/generator.ts @@ -0,0 +1,93 @@ +import { Contracts } from "ts-extractor"; +import * as path from "path"; +import * as fs from "fs-extra"; + +import { GeneratorConfiguration } from "./contracts/generator-configuration"; +import { FileManager } from "./file-manager"; +import { ApiDefaultPlugin } from "./plugins/api-default-plugin"; + +import { ApiItemReference } from "./contracts/api-item-reference"; +import { PluginResult, PluginOptions, GetItemPluginResultHandler } from "./contracts/plugin"; +import { FileResult } from "./contracts/file-result"; +import { PluginResultRegistry } from "./contracts/plugin-result-registry"; +import { PluginResultRegistry as PluginResultRegistryClass } from "./registries/plugin-result-registry"; + +export class Generator { + constructor(private configuration: GeneratorConfiguration) { + this.fileManager = new FileManager(); + this.pluginResultRegistry = new PluginResultRegistryClass(); + const { ExtractedData } = this.configuration; + + for (const entryFile of ExtractedData.EntryFiles) { + const sourceFile = ExtractedData.Registry[entryFile]; + const pluginResult + = this.renderApiItem({ Alias: sourceFile.Name, Id: entryFile }, sourceFile) as PluginResult; + + this.fileManager.AddEntryFile(pluginResult); + } + + this.outputData = this.fileManager.ToFilesOutput(); + } + + private pluginResultRegistry: PluginResultRegistry; + private fileManager: FileManager; + private outputData: FileResult[]; + + public get OutputData(): ReadonlyArray { + return this.outputData; + } + + public async WriteToFiles(): Promise { + for (const item of this.outputData) { + const fullLocation = path.join(this.configuration.OutputDirectory, "api", item.FileLocation); + + try { + // Ensure output directory + await fs.ensureDir(path.dirname(fullLocation)); + // Output file + await fs.writeFile(fullLocation, item.Result.join("\n")); + } catch (error) { + console.error(error); + } + } + } + + private getItemPluginResult: GetItemPluginResultHandler = (apiItemReference: ApiItemReference): PluginResult => { + const renderedItem = this.pluginResultRegistry.GetItem(apiItemReference); + + if (renderedItem == null) { + const { Registry } = this.configuration.ExtractedData; + + const pluginResult = this.renderApiItem(apiItemReference, Registry[apiItemReference.Id]); + this.pluginResultRegistry.AddItem(apiItemReference, pluginResult); + + return pluginResult; + } + + return renderedItem; + } + + private renderApiItem( + apiItemReference: ApiItemReference, + apiItem: Contracts.ApiItemDto + ): PluginResult { + const plugins = this.configuration.PluginManager.GetPluginsByKind(apiItem.ApiKind); + + const pluginOptions: PluginOptions = { + ExtractedData: this.configuration.ExtractedData, + Reference: apiItemReference, + ApiItem: apiItem, + GetItemPluginResult: this.getItemPluginResult, + IsPluginResultExists: reference => this.pluginResultRegistry.Exists(reference) + }; + + for (const plugin of plugins) { + if (plugin.CheckApiItem(apiItem)) { + return plugin.Render(pluginOptions); + } + } + + const defaultPlugin = new ApiDefaultPlugin(); + return defaultPlugin.Render(pluginOptions); + } +} diff --git a/packages/ts-docs-gen/src/index.ts b/packages/ts-docs-gen/src/index.ts new file mode 100644 index 00000000..e69de29b diff --git a/packages/ts-docs-gen/src/plugins/api-callable-plugin.ts b/packages/ts-docs-gen/src/plugins/api-callable-plugin.ts new file mode 100644 index 00000000..6075f2d9 --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-callable-plugin.ts @@ -0,0 +1,69 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; + +import { SupportedApiItemKindType, PluginResult, PluginOptions } from "../contracts/plugin"; +import { GeneratorHelpers } from "../generator-helpers"; +import { FunctionLikePlugin } from "../abstractions/function-like-plugin"; + +export type CallableApiItem = Contracts.ApiCallDto | Contracts.ApiMethodDto | Contracts.ApiConstructDto; + +export class ApiCallablePlugin extends FunctionLikePlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [ + GeneratorHelpers.ApiItemKinds.Construct, + GeneratorHelpers.ApiItemKinds.Call, + GeneratorHelpers.ApiItemKinds.Method + ]; + } + + private resolveItemCode( + apiItem: CallableApiItem, + parameters: Contracts.ApiParameterDto[], + typeParameters: Contracts.ApiTypeParameterDto[] + ): string { + switch (apiItem.ApiKind) { + case Contracts.ApiItemKinds.Construct: { + return GeneratorHelpers.ApiConstructToString(typeParameters, parameters, apiItem.ReturnType); + } + case Contracts.ApiItemKinds.Call: { + return GeneratorHelpers.ApiCallToString(typeParameters, parameters, apiItem.ReturnType); + } + case Contracts.ApiItemKinds.Method: { + return GeneratorHelpers.ApiMethodToString(apiItem.Name, typeParameters, parameters, apiItem.ReturnType); + } + } + } + + public Render(options: PluginOptions): PluginResult { + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: options.ApiItem, + Reference: options.Reference + }; + + // ApiParameters + const apiParameters = + GeneratorHelpers.GetApiItemsFromReference(options.ApiItem.Parameters, options.ExtractedData); + // ApiTypeParameters + const apiTypeParameters = + GeneratorHelpers.GetApiItemsFromReference(options.ApiItem.TypeParameters, options.ExtractedData); + + pluginResult.Result = new MarkdownBuilder() + .Code(this.resolveItemCode(options.ApiItem, apiParameters, apiTypeParameters), GeneratorHelpers.DEFAULT_CODE_OPTIONS) + .GetOutput(); + + // TypeParameters + const typeParametersResult = this.RenderTypeParameters(apiTypeParameters); + GeneratorHelpers.MergePluginResultData(pluginResult, typeParametersResult); + + // Parameters + const parametersResult = this.RenderParameters(apiParameters); + GeneratorHelpers.MergePluginResultData(pluginResult, parametersResult); + + // ReturnType + const returnTypeResult = this.RenderReturnType(options.ApiItem.ReturnType); + GeneratorHelpers.MergePluginResultData(pluginResult, returnTypeResult); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-class-accessor-plugin.ts b/packages/ts-docs-gen/src/plugins/api-class-accessor-plugin.ts new file mode 100644 index 00000000..607b3437 --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-class-accessor-plugin.ts @@ -0,0 +1,80 @@ +import { Contracts, ExtractDto } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; + +import { SupportedApiItemKindType, PluginOptions, PluginResult } from "../contracts/plugin"; +import { GeneratorHelpers } from "../generator-helpers"; +import { BasePlugin } from "../abstractions/base-plugin"; + +export type Kind = Contracts.ApiSetAccessorDto | Contracts.ApiGetAccessorDto; + +export class ApiClassAccessorPlugin extends BasePlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [ + GeneratorHelpers.ApiItemKinds.GetAccessor, + GeneratorHelpers.ApiItemKinds.SetAccessor, + ]; + } + + private getHeading(data: PluginOptions): string { + let accessorType: string; + if (data.ApiItem.ApiKind === Contracts.ApiItemKinds.SetAccessor) { + accessorType = "set"; + } else { + accessorType = "get"; + } + + return `${accessorType} ${data.Reference.Alias}`; + } + + private resolveType(apiItem: Kind, extractedData: ExtractDto): Contracts.TypeDto | undefined { + let type: Contracts.TypeDto | undefined; + if (apiItem.ApiKind === Contracts.ApiItemKinds.GetAccessor) { + // GetAccessor + + type = apiItem.Type; + } else if (apiItem.Parameter != null) { + // SetAccessor + + const apiParameter = extractedData.Registry[apiItem.Parameter.Ids[0]] as Contracts.ApiParameterDto; + if (apiParameter != null) { + type = apiParameter.Type; + } + } + + return type; + } + + public Render(options: PluginOptions): PluginResult { + const heading = this.getHeading(options); + const type = this.resolveType(options.ApiItem, options.ExtractedData); + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: options.ApiItem, + Reference: options.Reference, + Headings: [ + { + ApiItemId: options.Reference.Id, + Heading: heading + } + ] + }; + + // Header + pluginResult.Result = new MarkdownBuilder() + .Header(heading, 3) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(options.ApiItem)) + .Code(GeneratorHelpers.ApiAccessorToString( + options.ApiItem, + type, + options.Reference.Alias + ), GeneratorHelpers.DEFAULT_CODE_OPTIONS) + .GetOutput(); + + // Type + const typeResult = this.RenderType(type); + GeneratorHelpers.MergePluginResultData(pluginResult, typeResult); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-class-constructor-plugin.ts b/packages/ts-docs-gen/src/plugins/api-class-constructor-plugin.ts new file mode 100644 index 00000000..f90ef37d --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-class-constructor-plugin.ts @@ -0,0 +1,45 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; + +import { SupportedApiItemKindType, PluginOptions, PluginResult } from "../contracts/plugin"; +import { GeneratorHelpers } from "../generator-helpers"; +import { FunctionLikePlugin } from "../abstractions/function-like-plugin"; + +export class ApiClassConstructorPlugin extends FunctionLikePlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.ClassConstructor]; + } + + public Render(options: PluginOptions): PluginResult { + // ApiParameters + const apiParameters = GeneratorHelpers + .GetApiItemsFromReference(options.ApiItem.Parameters, options.ExtractedData); + + const heading = GeneratorHelpers.MethodToSimpleString("constructor", apiParameters); + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: options.ApiItem, + Reference: options.Reference, + Headings: [ + { + Heading: heading, + ApiItemId: options.Reference.Id + } + ] + }; + + // Header + pluginResult.Result = new MarkdownBuilder() + .Header(heading, 3) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(options.ApiItem)) + .Code(GeneratorHelpers.ApiClassConstructorToString(options.ApiItem, apiParameters), GeneratorHelpers.DEFAULT_CODE_OPTIONS) + .GetOutput(); + + // Parameters + const parametersResult = this.RenderParameters(apiParameters); + GeneratorHelpers.MergePluginResultData(pluginResult, parametersResult); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-class-method-plugin.ts b/packages/ts-docs-gen/src/plugins/api-class-method-plugin.ts new file mode 100644 index 00000000..5da07cf0 --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-class-method-plugin.ts @@ -0,0 +1,65 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; + +import { SupportedApiItemKindType, PluginOptions, PluginResult } from "../contracts/plugin"; +import { GeneratorHelpers } from "../generator-helpers"; +import { FunctionLikePlugin } from "../abstractions/function-like-plugin"; + +export class ApiClassMethodPlugin extends FunctionLikePlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.ClassMethod]; + } + + public CheckApiItem(item: Contracts.ApiItemDto): boolean { + return true; + } + + public Render(options: PluginOptions): PluginResult { + // Parameters + const apiParameters = GeneratorHelpers + .GetApiItemsFromReference(options.ApiItem.Parameters, options.ExtractedData); + // TypeParameters + const apiTypeParameters = GeneratorHelpers + .GetApiItemsFromReference(options.ApiItem.TypeParameters, options.ExtractedData); + + const heading = GeneratorHelpers.MethodToSimpleString(options.Reference.Alias, apiParameters); + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: options.ApiItem, + Reference: options.Reference, + Headings: [ + { + Heading: heading, + ApiItemId: options.Reference.Id + } + ] + }; + + // Header + pluginResult.Result = new MarkdownBuilder() + .Header(heading, 3) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(options.ApiItem)) + .Code(GeneratorHelpers.ApiClassMethodToString( + options.ApiItem, + apiTypeParameters, + apiParameters, + options.Reference.Alias + ), GeneratorHelpers.DEFAULT_CODE_OPTIONS) + .GetOutput(); + + // TypeParameters + const typeParametersResult = this.RenderTypeParameters(apiTypeParameters); + GeneratorHelpers.MergePluginResultData(pluginResult, typeParametersResult); + + // Parameters + const parametersResult = this.RenderParameters(apiParameters); + GeneratorHelpers.MergePluginResultData(pluginResult, parametersResult); + + // ReturnType + const returnTypeResult = this.RenderReturnType(options.ApiItem.ReturnType); + GeneratorHelpers.MergePluginResultData(pluginResult, returnTypeResult); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-class-plugin.ts b/packages/ts-docs-gen/src/plugins/api-class-plugin.ts new file mode 100644 index 00000000..443c0227 --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-class-plugin.ts @@ -0,0 +1,72 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; +import * as path from "path"; + +import { GeneratorHelpers } from "../generator-helpers"; +import { SupportedApiItemKindType, PluginOptions, PluginResult } from "../contracts/plugin"; +import { ContainerPlugin, ContainerMembersKindsGroup } from "../abstractions/container-plugin"; + +export class ApiClassPlugin extends ContainerPlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.Class]; + } + + public Render(data: PluginOptions): PluginResult { + const heading = path.basename(data.ApiItem.Name, path.extname(data.ApiItem.Name)); + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: data.ApiItem, + Reference: data.Reference, + Headings: [ + { + Heading: heading, + ApiItemId: data.Reference.Id + } + ] + }; + + // Resolve ApiItems from references. + const typeParameters = GeneratorHelpers + .GetApiItemsFromReference(data.ApiItem.TypeParameters, data.ExtractedData); + + // Header + pluginResult.Result = new MarkdownBuilder() + .Header(heading, 1) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(data.ApiItem)) + .Code(GeneratorHelpers.ClassToString( + data.ApiItem, + typeParameters, + data.Reference.Alias + ), GeneratorHelpers.DEFAULT_CODE_OPTIONS) + .GetOutput(); + + // ApiMembers + const memberKindsList: ContainerMembersKindsGroup[] = [ + { + Heading: "Index", + Kinds: [Contracts.ApiItemKinds.Index] + }, + { + Heading: "Constructor", + Kinds: [Contracts.ApiItemKinds.ClassConstructor] + }, + { + Heading: "Methods", + Kinds: [Contracts.ApiItemKinds.ClassMethod] + }, + { + Heading: "Properties", + Kinds: [ + Contracts.ApiItemKinds.ClassProperty, + Contracts.ApiItemKinds.GetAccessor, + Contracts.ApiItemKinds.SetAccessor, + ] + } + ]; + const members = this.RenderMembersGroups(memberKindsList, data); + GeneratorHelpers.MergePluginResultData(pluginResult, members); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-class-property-plugin.ts b/packages/ts-docs-gen/src/plugins/api-class-property-plugin.ts new file mode 100644 index 00000000..36144af9 --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-class-property-plugin.ts @@ -0,0 +1,43 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; + +import { SupportedApiItemKindType, PluginOptions, PluginResult } from "../contracts/plugin"; +import { GeneratorHelpers } from "../generator-helpers"; +import { BasePlugin } from "../abstractions/base-plugin"; + +export class ApiClassPropertyPlugin extends BasePlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.ClassProperty]; + } + + public Render(options: PluginOptions): PluginResult { + const heading = options.Reference.Alias; + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: options.ApiItem, + Reference: options.Reference, + Headings: [ + { + ApiItemId: options.Reference.Id, + Heading: heading + } + ] + }; + + // Header + pluginResult.Result = new MarkdownBuilder() + .Header(heading, 3) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(options.ApiItem)) + .Code(GeneratorHelpers.ApiClassPropertyToString( + options.ApiItem, + options.Reference.Alias + ), GeneratorHelpers.DEFAULT_CODE_OPTIONS) + .GetOutput(); + + const typeResult = this.RenderType(options.ApiItem.Type); + GeneratorHelpers.MergePluginResultData(pluginResult, typeResult); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-default-plugin.ts b/packages/ts-docs-gen/src/plugins/api-default-plugin.ts new file mode 100644 index 00000000..78e9a57d --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-default-plugin.ts @@ -0,0 +1,37 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; + +import { PluginOptions, PluginResult, SupportedApiItemKindType } from "../contracts/plugin"; +import { GeneratorHelpers } from "../generator-helpers"; +import { BasePlugin } from "../abstractions/base-plugin"; + +export class ApiDefaultPlugin extends BasePlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.Any]; + } + + public Render(options: PluginOptions): PluginResult { + const heading = `${options.ApiItem.ApiKind}: ${options.Reference.Alias}`; + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: options.ApiItem, + Reference: options.Reference, + Headings: [ + { + Heading: heading, + ApiItemId: options.Reference.Id + } + ] + }; + + pluginResult.Result = new MarkdownBuilder() + .Header(heading, 3) + .EmptyLine() + .Bold(`Warning: unsupported api item kind ${options.ApiItem.ApiKind}!`) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(options.ApiItem)) + .GetOutput(); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-enum-plugin.ts b/packages/ts-docs-gen/src/plugins/api-enum-plugin.ts new file mode 100644 index 00000000..63148d96 --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-enum-plugin.ts @@ -0,0 +1,63 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownGenerator, MarkdownBuilder } from "@simplrjs/markdown"; + +import { GeneratorHelpers } from "../generator-helpers"; +import { SupportedApiItemKindType, PluginResult, PluginOptions } from "../contracts/plugin"; +import { BasePlugin } from "../abstractions/base-plugin"; + +export class ApiEnumPlugin extends BasePlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.Enum]; + } + + public CheckApiItem(item: Contracts.ApiItemDto): boolean { + return true; + } + + private renderEnumTable(members: Contracts.ApiEnumMemberDto[]): string[] { + // Table header. + const header = ["Name", "Value", "Description"]; + const content = members.map(x => [x.Name, x.Value, x.Metadata.DocumentationComment]); + + return MarkdownGenerator.Table(header, content, { removeColumnIfEmpty: true }); + } + + public Render(options: PluginOptions): PluginResult { + const heading: string = options.Reference.Alias; + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: options.ApiItem, + Reference: options.Reference, + Headings: [ + { + Heading: heading, + ApiItemId: options.Reference.Id + } + ] + }; + + // Enum members + const enumMembers = GeneratorHelpers.GetApiItemsFromReference( + options.ApiItem.Members, + options.ExtractedData + ); + + pluginResult.Result = new MarkdownBuilder() + .Header(heading, 3) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(options.ApiItem)) + .EmptyLine() + .Code(GeneratorHelpers.ApiEnumToString( + options.ApiItem, + enumMembers, + options.Reference.Alias + ), GeneratorHelpers.DEFAULT_CODE_OPTIONS) + .EmptyLine() + .Bold("Members") + .EmptyLine() + .Text(this.renderEnumTable(enumMembers)) + .GetOutput(); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-function-plugin.ts b/packages/ts-docs-gen/src/plugins/api-function-plugin.ts new file mode 100644 index 00000000..bee15bf0 --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-function-plugin.ts @@ -0,0 +1,61 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; + +import { GeneratorHelpers } from "../generator-helpers"; +import { SupportedApiItemKindType, PluginResult, PluginOptions } from "../contracts/plugin"; +import { FunctionLikePlugin } from "../abstractions/function-like-plugin"; + +export class ApiFunctionPlugin extends FunctionLikePlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.Function]; + } + + public Render(options: PluginOptions): PluginResult { + // Parameters + const apiParameters = GeneratorHelpers + .GetApiItemsFromReference(options.ApiItem.Parameters, options.ExtractedData); + // TypeParameters + const apiTypeParameters = GeneratorHelpers + .GetApiItemsFromReference(options.ApiItem.TypeParameters, options.ExtractedData); + + const heading = GeneratorHelpers.MethodToSimpleString(options.Reference.Alias, apiParameters); + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: options.ApiItem, + Reference: options.Reference, + Headings: [ + { + Heading: heading, + ApiItemId: options.Reference.Id + } + ] + }; + + // Header + pluginResult.Result = new MarkdownBuilder() + .Header(heading, 3) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(options.ApiItem)) + .Code(GeneratorHelpers.ApiFunctionToString( + options.ApiItem, + apiTypeParameters, + apiParameters, + options.Reference.Alias + ), GeneratorHelpers.DEFAULT_CODE_OPTIONS) + .GetOutput(); + + // TypeParameters + const typeParametersResult = this.RenderTypeParameters(apiTypeParameters); + GeneratorHelpers.MergePluginResultData(pluginResult, typeParametersResult); + + // Parameters + const parametersResult = this.RenderParameters(apiParameters); + GeneratorHelpers.MergePluginResultData(pluginResult, parametersResult); + + // ReturnType + const returnTypeResult = this.RenderReturnType(options.ApiItem.ReturnType); + GeneratorHelpers.MergePluginResultData(pluginResult, returnTypeResult); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-index-plugin.ts b/packages/ts-docs-gen/src/plugins/api-index-plugin.ts new file mode 100644 index 00000000..d8b2b228 --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-index-plugin.ts @@ -0,0 +1,47 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder, MarkdownGenerator as md } from "@simplrjs/markdown"; + +import { SupportedApiItemKindType, PluginResult, PluginOptions } from "../contracts/plugin"; +import { GeneratorHelpers } from "../generator-helpers"; +import { BasePlugin } from "../abstractions/base-plugin"; + +export class ApiIndexPlugin extends BasePlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.Index]; + } + + public Render(options: PluginOptions): PluginResult { + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: options.ApiItem, + Reference: options.Reference + }; + // Parameter + const parameter = options.ExtractedData.Registry[options.ApiItem.Parameter] as Contracts.ApiParameterDto; + + // Types + const parameterType = GeneratorHelpers.TypeDtoToMarkdownString(parameter.Type); + const indexType = GeneratorHelpers.TypeDtoToMarkdownString(options.ApiItem.Type); + GeneratorHelpers.MergePluginResultData(pluginResult, { + UsedReferences: [ + ...parameterType.References, + ...indexType.References + ] + }); + + // Header + const indexDeclarationString = GeneratorHelpers.ApiIndexToString(parameter, options.ApiItem.Type, options.ApiItem.IsReadonly); + const builder = new MarkdownBuilder() + .Code(indexDeclarationString, GeneratorHelpers.DEFAULT_CODE_OPTIONS) + .EmptyLine(); + + pluginResult.Result = builder + .UnorderedList([ + `${md.Italic("Parameter")} ${md.InlineCode(parameter.Name)} - ${parameterType.Text}`, + `${md.Italic("Type")} ${indexType.Text}` + ]) + .GetOutput(); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-interface-plugin.ts b/packages/ts-docs-gen/src/plugins/api-interface-plugin.ts new file mode 100644 index 00000000..2d008c14 --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-interface-plugin.ts @@ -0,0 +1,187 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder, MarkdownGenerator } from "@simplrjs/markdown"; + +import { + SupportedApiItemKindType, + PluginResult, + PluginOptions, + GetItemPluginResultHandler, + PluginResultData +} from "../contracts/plugin"; +import { GeneratorHelpers } from "../generator-helpers"; +import { ApiItemReference } from "../contracts/api-item-reference"; +import { BasePlugin } from "../abstractions/base-plugin"; + +interface ExtractedItemDto { + Reference: ApiItemReference; + ApiItem: TApiItemDto; +} + +export class ApiInterfacePlugin extends BasePlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.Interface]; + } + + private renderConstraintTypes(apiItem: Contracts.ApiInterfaceDto): PluginResultData | undefined { + if (apiItem.Extends.length === 0) { + return undefined; + } + + const builder = new MarkdownBuilder() + .EmptyLine() + .Bold("Extends"); + + const references = []; + + for (const type of apiItem.Extends) { + const typeDto = GeneratorHelpers.TypeDtoToMarkdownString(type); + references.push(...typeDto.References); + builder + .EmptyLine() + .Text(typeDto.Text); + } + + return { + ...GeneratorHelpers.GetDefaultPluginResultData(), + UsedReferences: references, + Result: builder.GetOutput(), + }; + } + + private renderPropertyMembers(memberItems: ExtractedItemDto[]): PluginResultData | undefined { + const apiItems = memberItems.filter>( + this.isReferenceOfApiItemKind.bind(undefined, Contracts.ApiItemKinds.Property) + ).map(x => x.ApiItem); + + if (apiItems.length === 0) { + return undefined; + } + + const table = GeneratorHelpers.ApiPropertiesToTableString(apiItems); + const builder = new MarkdownBuilder() + .EmptyLine() + .Bold("Properties") + .EmptyLine() + .Text(table.Text); + + return { + ...GeneratorHelpers.GetDefaultPluginResultData(), + UsedReferences: table.References, + Result: builder.GetOutput(), + }; + } + + private isReferenceOfApiItemKind( + itemKind: Contracts.ApiItemKinds, + extractedItem: ExtractedItemDto + ): extractedItem is ExtractedItemDto { + return extractedItem.ApiItem.ApiKind === itemKind; + } + + private renderMemberItemsGroup( + title: string, + apiItemKind: Contracts.ApiItemKinds, + memberItems: ExtractedItemDto[], + getPluginResult: GetItemPluginResultHandler + ): PluginResultData | undefined { + const items = memberItems.filter(this.isReferenceOfApiItemKind.bind(undefined, apiItemKind)); + + if (items.length === 0) { + return undefined; + } + + const pluginResult = GeneratorHelpers.GetDefaultPluginResultData(); + pluginResult.Result.push("", MarkdownGenerator.Header(title, 4)); + + for (const item of items) { + pluginResult.Result.push(""); + const itemPluginResult = getPluginResult(item.Reference); + + GeneratorHelpers.MergePluginResultData(pluginResult, itemPluginResult); + } + + return pluginResult; + } + + public Render(options: PluginOptions): PluginResult { + const heading = options.Reference.Alias; + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: options.ApiItem, + Reference: options.Reference, + Headings: [ + { + ApiItemId: options.Reference.Id, + Heading: heading + } + ] + }; + + const memberReferences = GeneratorHelpers.GetApiItemReferences(options.ExtractedData, options.ApiItem.Members); + const memberItems = memberReferences.map(itemReference => ({ + Reference: itemReference, + ApiItem: options.ExtractedData.Registry[itemReference.Id] + })); + + const interfaceString = GeneratorHelpers.ApiInterfaceToString(options.ApiItem, options.ExtractedData); + const builder = new MarkdownBuilder() + .Header(heading, 3) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(options.ApiItem)) + .Code(interfaceString, GeneratorHelpers.DEFAULT_CODE_OPTIONS); + + pluginResult.Result = builder.GetOutput(); + + // Type parameters + const apiTypeParameters = GeneratorHelpers + .GetApiItemsFromReference(options.ApiItem.TypeParameters, options.ExtractedData); + const typeParametersResult = this.RenderTypeParameters(apiTypeParameters); + GeneratorHelpers.MergePluginResultData(pluginResult, typeParametersResult); + + // Constraint types + const constraintTypesResult = this.renderConstraintTypes(options.ApiItem); + GeneratorHelpers.MergePluginResultData(pluginResult, constraintTypesResult); + + // Construct items + const constructMembersResult = this.renderMemberItemsGroup( + "Construct", + Contracts.ApiItemKinds.Construct, + memberItems, + options.GetItemPluginResult + ); + GeneratorHelpers.MergePluginResultData(pluginResult, constructMembersResult); + + // Call items + const callMembersResult = this.renderMemberItemsGroup( + "Call", + Contracts.ApiItemKinds.Call, + memberItems, + options.GetItemPluginResult + ); + GeneratorHelpers.MergePluginResultData(pluginResult, callMembersResult); + + // Index items + const indexMembersResult = this.renderMemberItemsGroup( + "Index signatures", + Contracts.ApiItemKinds.Index, + memberItems, + options.GetItemPluginResult + ); + GeneratorHelpers.MergePluginResultData(pluginResult, indexMembersResult); + + // Method items + const methodMembersResult = this.renderMemberItemsGroup( + "Methods", + Contracts.ApiItemKinds.Method, + memberItems, + options.GetItemPluginResult + ); + GeneratorHelpers.MergePluginResultData(pluginResult, methodMembersResult); + + // Property items + const propertyMembersResult = this.renderPropertyMembers(memberItems); + GeneratorHelpers.MergePluginResultData(pluginResult, propertyMembersResult); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-namespace-plugin.ts b/packages/ts-docs-gen/src/plugins/api-namespace-plugin.ts new file mode 100644 index 00000000..a20f0c92 --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-namespace-plugin.ts @@ -0,0 +1,71 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; +import * as path from "path"; + +import { GeneratorHelpers } from "../generator-helpers"; +import { SupportedApiItemKindType, PluginOptions, PluginResult } from "../contracts/plugin"; +import { ContainerPlugin, ContainerMembersKindsGroup } from "../abstractions/container-plugin"; + +export class ApiNamespacePlugin extends ContainerPlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.Namespace]; + } + + public Render(data: PluginOptions): PluginResult { + const heading = path.basename(data.ApiItem.Name, path.extname(data.ApiItem.Name)); + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: data.ApiItem, + Reference: data.Reference, + Headings: [ + { + Heading: heading, + ApiItemId: data.Reference.Id + } + ] + }; + + // Header + pluginResult.Result = new MarkdownBuilder() + .Header(heading, 1) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(data.ApiItem)) + .GetOutput(); + + // Members + const memberKindsList: ContainerMembersKindsGroup[] = [ + { + Heading: "Functions", + Kinds: [Contracts.ApiItemKinds.Function] + }, + { + Heading: "Interfaces", + Kinds: [Contracts.ApiItemKinds.Interface] + }, + { + Heading: "Types", + Kinds: [Contracts.ApiItemKinds.Type] + }, + { + Heading: "Enums", + Kinds: [Contracts.ApiItemKinds.Enum] + }, + { + Heading: "Classes", + Kinds: [Contracts.ApiItemKinds.Class] + }, + { + Heading: "Namespaces", + Kinds: [Contracts.ApiItemKinds.Namespace] + }, + { + Heading: "Variables", + Kinds: [Contracts.ApiItemKinds.Variable] + } + ]; + const renderedMembers = this.RenderMembersGroups(memberKindsList, data); + GeneratorHelpers.MergePluginResultData(pluginResult, renderedMembers); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-source-file-plugin.ts b/packages/ts-docs-gen/src/plugins/api-source-file-plugin.ts new file mode 100644 index 00000000..fbc6c42f --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-source-file-plugin.ts @@ -0,0 +1,71 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; +import * as path from "path"; + +import { GeneratorHelpers } from "../generator-helpers"; +import { SupportedApiItemKindType, PluginOptions, PluginResult } from "../contracts/plugin"; +import { ContainerPlugin, ContainerMembersKindsGroup } from "../abstractions/container-plugin"; + +export class ApiSourceFilePlugin extends ContainerPlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.SourceFile]; + } + + public Render(data: PluginOptions): PluginResult { + const heading = path.basename(data.ApiItem.Name, path.extname(data.ApiItem.Name)); + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: data.ApiItem, + Reference: data.Reference, + Headings: [ + { + Heading: heading, + ApiItemId: data.Reference.Id + } + ] + }; + + // Header + pluginResult.Result = new MarkdownBuilder() + .Header(heading, 1) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(data.ApiItem)) + .GetOutput(); + + // Members + const memberKindsList: ContainerMembersKindsGroup[] = [ + { + Heading: "Functions", + Kinds: [Contracts.ApiItemKinds.Function] + }, + { + Heading: "Interfaces", + Kinds: [Contracts.ApiItemKinds.Interface] + }, + { + Heading: "Types", + Kinds: [Contracts.ApiItemKinds.Type] + }, + { + Heading: "Enums", + Kinds: [Contracts.ApiItemKinds.Enum] + }, + { + Heading: "Classes", + Kinds: [Contracts.ApiItemKinds.Class] + }, + { + Heading: "Namespaces", + Kinds: [Contracts.ApiItemKinds.Namespace] + }, + { + Heading: "Variables", + Kinds: [Contracts.ApiItemKinds.Variable] + } + ]; + const members = this.RenderMembersGroups(memberKindsList, data); + GeneratorHelpers.MergePluginResultData(pluginResult, members); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-type-plugin.ts b/packages/ts-docs-gen/src/plugins/api-type-plugin.ts new file mode 100644 index 00000000..4e83a89e --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-type-plugin.ts @@ -0,0 +1,47 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; + +import { GeneratorHelpers } from "../generator-helpers"; +import { SupportedApiItemKindType, PluginOptions, PluginResult } from "../contracts/plugin"; +import { BasePlugin } from "../abstractions/base-plugin"; + +export class ApiTypePlugin extends BasePlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.Type]; + } + + public Render(options: PluginOptions): PluginResult { + const heading = options.Reference.Alias; + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: options.ApiItem, + Reference: options.Reference, + Headings: [ + { + Heading: heading, + ApiItemId: options.Reference.Id + } + ] + }; + + // Header + pluginResult.Result = new MarkdownBuilder() + .Header(heading, 3) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(options.ApiItem)) + .Code(GeneratorHelpers.ApiTypeToString(options.ApiItem), GeneratorHelpers.DEFAULT_CODE_OPTIONS) + .GetOutput(); + + // TypeParameters + const apiTypeParameters = GeneratorHelpers + .GetApiItemsFromReference(options.ApiItem.TypeParameters, options.ExtractedData); + const typeParametersResult = this.RenderTypeParameters(apiTypeParameters); + GeneratorHelpers.MergePluginResultData(pluginResult, typeParametersResult); + + // Type + const typeResult = this.RenderType(options.ApiItem.Type); + GeneratorHelpers.MergePluginResultData(pluginResult, typeResult); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/plugins/api-variable-plugin.ts b/packages/ts-docs-gen/src/plugins/api-variable-plugin.ts new file mode 100644 index 00000000..1f01c288 --- /dev/null +++ b/packages/ts-docs-gen/src/plugins/api-variable-plugin.ts @@ -0,0 +1,43 @@ +import { Contracts } from "ts-extractor"; +import { MarkdownBuilder } from "@simplrjs/markdown"; + +import { GeneratorHelpers } from "../generator-helpers"; +import { SupportedApiItemKindType, PluginOptions, PluginResult } from "../contracts/plugin"; +import { BasePlugin } from "../abstractions/base-plugin"; + +export class ApiVariablePlugin extends BasePlugin { + public SupportedApiItemKinds(): SupportedApiItemKindType[] { + return [GeneratorHelpers.ApiItemKinds.Variable]; + } + + public Render(options: PluginOptions): PluginResult { + const heading: string = options.Reference.Alias; + const pluginResult: PluginResult = { + ...GeneratorHelpers.GetDefaultPluginResultData(), + ApiItem: options.ApiItem, + Reference: options.Reference, + Headings: [ + { + Heading: heading, + ApiItemId: options.Reference.Id + } + ] + }; + + // Type + const typeStringDto = GeneratorHelpers.TypeDtoToMarkdownString(options.ApiItem.Type); + + pluginResult.Result = new MarkdownBuilder() + .Header(heading, 3) + .EmptyLine() + .Text(GeneratorHelpers.RenderApiItemMetadata(options.ApiItem)) + .Code(GeneratorHelpers.ApiVariableToString(options.ApiItem), GeneratorHelpers.DEFAULT_CODE_OPTIONS) + .EmptyLine() + .Bold("Type") + .EmptyLine() + .Text(typeStringDto.Text) + .GetOutput(); + + return pluginResult; + } +} diff --git a/packages/ts-docs-gen/src/registries/plugin-registry.ts b/packages/ts-docs-gen/src/registries/plugin-registry.ts new file mode 100644 index 00000000..3f8e203b --- /dev/null +++ b/packages/ts-docs-gen/src/registries/plugin-registry.ts @@ -0,0 +1,39 @@ +import { Contracts } from "ts-extractor"; +import { Plugin, SupportedApiItemKindType, ApiItemKindsAdditional } from "../contracts/plugin"; + +export class PluginRegistry { + constructor() { + + // Initialize Plugins map. + for (const [, kindValue] of Object.entries(Contracts.ApiItemKinds)) { + this.registeredPlugins.set(kindValue as Contracts.ApiItemKinds, []); + } + } + + private registeredPlugins: Map = new Map(); + + private isSupportedKindsHasAny(kinds: SupportedApiItemKindType[]): kinds is ApiItemKindsAdditional[] { + return Boolean(kinds.find(x => x === ApiItemKindsAdditional.Any)); + } + + public Register(plugin: Plugin): void { + const supportedKinds = plugin.SupportedApiItemKinds(); + + if (this.isSupportedKindsHasAny(supportedKinds)) { + for (const [key, value] of this.registeredPlugins) { + this.registeredPlugins.set(key, [plugin, ...value]); + } + return; + } + + // FIXME: Remove `as`. Somehow it doesn't work. + for (const kind of supportedKinds as Contracts.ApiItemKinds[]) { + const registeredPluginsOfKind = this.registeredPlugins.get(kind) || []; + this.registeredPlugins.set(kind, [plugin, ...registeredPluginsOfKind]); + } + } + + public GetPluginsByKind(kind: Contracts.ApiItemKinds): Plugin[] { + return this.registeredPlugins.get(kind) || []; + } +} diff --git a/packages/ts-docs-gen/src/registries/plugin-result-registry.ts b/packages/ts-docs-gen/src/registries/plugin-result-registry.ts new file mode 100644 index 00000000..d622c1db --- /dev/null +++ b/packages/ts-docs-gen/src/registries/plugin-result-registry.ts @@ -0,0 +1,36 @@ +import { ApiItemReference } from "../contracts/api-item-reference"; +import { PluginResult } from "../contracts/plugin"; +import { PluginResultRegistry as PluginResultRegistryInterface } from "../contracts/plugin-result-registry"; + +export class PluginResultRegistry implements PluginResultRegistryInterface { + private results: Map = new Map(); + + private getKey(itemReference: ApiItemReference): ApiItemReference | undefined { + for (const [reference] of this.results) { + if (itemReference.Alias === reference.Alias && + itemReference.Id === reference.Id) { + return reference; + } + } + + return undefined; + } + + public AddItem(itemReference: ApiItemReference, pluginResult: PluginResult): void { + const key = this.getKey(itemReference) || itemReference; + this.results.set(key, pluginResult); + } + + public GetItem(itemReference: ApiItemReference): PluginResult | undefined { + const realKey = this.getKey(itemReference); + if (realKey != null) { + return this.results.get(realKey); + } else { + return undefined; + } + } + + public Exists(itemReference: ApiItemReference): boolean { + return this.getKey(itemReference) != null; + } +} diff --git a/packages/ts-docs-gen/src/utils/helpers.ts b/packages/ts-docs-gen/src/utils/helpers.ts new file mode 100644 index 00000000..adbe288f --- /dev/null +++ b/packages/ts-docs-gen/src/utils/helpers.ts @@ -0,0 +1,11 @@ +export namespace Helpers { + export function Flatten(arr: any[][]): any[] { + return arr.reduce((flat, toFlatten) => + flat.concat(Array.isArray(toFlatten) ? Flatten(toFlatten) : toFlatten), []); + } + + // TODO: Move this to @simplrjs/markdown package. + export function HeadingToAnchor(heading: string): string { + return heading.trim().toLowerCase().replace(/[^\w\- ]+/g, "").replace(/\s/g, "-").replace(/\-+$/, ""); + } +} diff --git a/packages/ts-docs-gen/src/utils/logger.ts b/packages/ts-docs-gen/src/utils/logger.ts new file mode 100644 index 00000000..55b1a36d --- /dev/null +++ b/packages/ts-docs-gen/src/utils/logger.ts @@ -0,0 +1,7 @@ +import { LoggerBuilder, LoggerConfigurationBuilder, LogLevel } from "simplr-logger"; + +const LoggerConfiguration = new LoggerConfigurationBuilder() + .SetDefaultLogLevel(LogLevel.Trace) + .Build(); + +export const Logger = new LoggerBuilder(LoggerConfiguration); diff --git a/packages/ts-docs-gen/tests/cases/__tests__/__snapshots__/simple-project-1.test.ts.snap b/packages/ts-docs-gen/tests/cases/__tests__/__snapshots__/simple-project-1.test.ts.snap new file mode 100644 index 00000000..19bb8c47 --- /dev/null +++ b/packages/ts-docs-gen/tests/cases/__tests__/__snapshots__/simple-project-1.test.ts.snap @@ -0,0 +1,1018 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`simple-project-1 1`] = ` +Array [ + Object { + "FileLocation": "index.md", + "Result": Array [ + "[ClassDeclaration-2]: index/earth.md#earth", + "[ClassDeclaration-1]: index/world.md#world", + "[InterfaceDeclaration-1]: index.md#foointerface", + "[InterfaceDeclaration-2]: index.md#boo", + "[InterfaceDeclaration-4]: index.md#myconstrainttype", + "[InterfaceDeclaration-9]: index.md#dictionary", + "[InterfaceDeclaration-9]: index.md#dictionary", + "[InterfaceDeclaration-6]: index.md#objectsinterface", + "[InterfaceDeclaration-12]: index.md#monsterinterface", + "[ClassDeclaration-0]: index/foo.md#foo", + "[ClassDeclaration-1]: index/world.md#world", + "[ClassDeclaration-2]: index/earth.md#earth", + "# index", + "", + "## Functions", + "", + "### AnotherFoo(parameter1, parameter2)", + "", + "\`\`\`typescript", + "function AnotherFoo(parameter1: string, parameter2: Promise): string", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name | Constraint type |", + "| ---- | --------------- |", + "| T | Object |", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ---------- | -------------------- |", + "| parameter1 | string |", + "| parameter2 | Promise&\\\\#60;T&\\\\#62; |", + "", + "**Return type**", + "", + "string", + "", + "----------", + "", + "### GetFoo()", + "", + "\`\`\`typescript", + "function GetFoo(): Promise", + "\`\`\`", + "", + "**Return type**", + "", + "Promise<void>", + "", + "----------", + "", + "### FunctionWithOneParameter(parameter)", + "", + "\`\`\`typescript", + "function FunctionWithOneParameter(parameter: string): void", + "\`\`\`", + "", + "**Parameters**", + "", + "| Name | Type |", + "| --------- | ------ |", + "| parameter | string |", + "", + "**Return type**", + "", + "void", + "", + "----------", + "", + "### FunctionWithNoParameters()", + "", + "\`\`\`typescript", + "function FunctionWithNoParameters(): void", + "\`\`\`", + "", + "**Return type**", + "", + "void", + "", + "----------", + "", + "### FunctionWithMultipleParameters(parameter1, parameter2)", + "", + "\`\`\`typescript", + "function FunctionWithMultipleParameters(parameter1: string, parameter2: number): void", + "\`\`\`", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ---------- | ------ |", + "| parameter1 | string |", + "| parameter2 | number |", + "", + "**Return type**", + "", + "void", + "", + "----------", + "", + "### Bar(parameter1, parameter2)", + "", + "Warning: Beta!", + "", + "Deprecated!", + "", + "Some general comment about Bar function.", + "", + "\`\`\`typescript", + "function Bar(parameter1: string, parameter2: number): string", + "\`\`\`", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ---------- | ------ |", + "| parameter1 | string |", + "| parameter2 | number |", + "", + "**Return type**", + "", + "string", + "", + "----------", + "", + "### FunctionWithMultipleTypeParameters(parameter1, parameter2)", + "", + "Comment on Function with multiple type parameters.", + "", + "\`\`\`typescript", + "function FunctionWithMultipleTypeParameters(parameter1: T, parameter2: P): string", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name | Constraint type |", + "| ---- | --------------- |", + "| T | Object |", + "| P | |", + "", + "**Parameters**", + "", + "| Name | Type | Description |", + "| ---------- | ---- | --------------------- |", + "| parameter1 | T | Parameter one comment |", + "| parameter2 | P | Parameter two comment |", + "", + "**Return type**", + "", + "string", + "", + "----------", + "", + "### FunctionWithTypeParameterDefault(parameter1, parameter2)", + "", + "Some general comment about Function with type parameter default function.", + "", + "\`\`\`typescript", + "function FunctionWithTypeParameterDefault(parameter1: string, parameter2: T): string", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name | Constraint type | Default type |", + "| ---- | --------------- | ------------ |", + "| T | Object | {} |", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ---------- | ------ |", + "| parameter1 | string |", + "| parameter2 | T |", + "", + "**Return type**", + "", + "string", + "", + "----------", + "", + "### FunctionWithTypeParameterConstraint(parameter1, parameter2)", + "", + "Some general comment about AnotherBar function.", + "", + "\`\`\`typescript", + "function FunctionWithTypeParameterConstraint(parameter1: string, parameter2: T): string", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name | Constraint type |", + "| ---- | --------------- |", + "| T | Object |", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ---------- | ------ |", + "| parameter1 | string |", + "| parameter2 | T |", + "", + "**Return type**", + "", + "string", + "", + "----------", + "", + "### FunctionWithoutReturnType(parameter1, parameter2)", + "", + "\`\`\`typescript", + "function FunctionWithoutReturnType(parameter1: string, parameter2: Promise): string", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name | Constraint type |", + "| ---- | ---------------- |", + "| T | Array<T> |", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ---------- | -------------------- |", + "| parameter1 | string |", + "| parameter2 | Promise&\\\\#60;T&\\\\#62; |", + "", + "**Return type**", + "", + "string", + "", + "----------", + "", + "### FunctionWithGenericReturnType()", + "", + "\`\`\`typescript", + "function FunctionWithGenericReturnType(): string[]", + "\`\`\`", + "", + "**Return type**", + "", + "Array<string>", + "", + "----------", + "", + "### FunctionWithPrimitiveReturnType()", + "", + "\`\`\`typescript", + "function FunctionWithPrimitiveReturnType(): boolean", + "\`\`\`", + "", + "**Return type**", + "", + "true | false", + "", + "----------", + "", + "### FunctionWithUnionReturnType()", + "", + "\`\`\`typescript", + "function FunctionWithUnionReturnType(): \\"something\\" | \\"nothing\\"", + "\`\`\`", + "", + "**Return type**", + "", + "\\"something\\" | \\"nothing\\"", + "", + "----------", + "", + "### FunctionWithIntersectionReturnType()", + "", + "\`\`\`typescript", + "function FunctionWithIntersectionReturnType(): Earth & World", + "\`\`\`", + "", + "**Return type**", + "", + "[Earth][ClassDeclaration-2] & [World][ClassDeclaration-1]", + "", + "----------", + "", + "### MyFunction()", + "", + "Function with TypeParameter as TypeLiteral.", + "", + "\`\`\`typescript", + "function MyFunction(): T", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name | Constraint type | Default type |", + "| ---- | ----------------------------------------------------------- | ----------------------- |", + "| T | { myProperty: string; myPropertyTwo?: number | undefined; } | { myProperty: string; } |", + "", + "**Return type**", + "", + "T", + "", + "----------", + "", + "### FunctionWithInitializedNumberParameter(someParameter)", + "", + "\`\`\`typescript", + "function FunctionWithInitializedNumberParameter(someParameter: number = 12): number", + "\`\`\`", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ------------- | ------ |", + "| someParameter | number |", + "", + "**Return type**", + "", + "number", + "", + "----------", + "", + "### FunctionWithInitializedStringParameter(someParameter)", + "", + "\`\`\`typescript", + "function FunctionWithInitializedStringParameter(someParameter: string = \\"12\\"): string", + "\`\`\`", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ------------- | ------ |", + "| someParameter | string |", + "", + "**Return type**", + "", + "string", + "", + "## Interfaces", + "", + "### ExtendedBar", + "", + "\`\`\`typescript", + "interface ExtendedBar extends FooInterface, Boo {", + " OtherStuff: string[];", + "}", + "\`\`\`", + "", + "**Extends**", + "", + "[FooInterface][InterfaceDeclaration-1]<number>", + "", + "[Boo][InterfaceDeclaration-2]", + "", + "**Properties**", + "", + "| Name | Type |", + "| ---------- | --------------------- |", + "| OtherStuff | Array<string> |", + "", + "----------", + "", + "### FooInterface", + "", + "\`\`\`typescript", + "interface FooInterface {", + " Name: string;", + " Surname: string;", + " Type: TType;", + "}", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name |", + "| ----- |", + "| TType |", + "", + "**Properties**", + "", + "| Name | Type |", + "| ------- | ------ |", + "| Name | string |", + "| Surname | string |", + "| Type | TType |", + "", + "----------", + "", + "### Boo", + "", + "\`\`\`typescript", + "interface Boo {", + " Boos: string[];", + "}", + "\`\`\`", + "", + "**Properties**", + "", + "| Name | Type |", + "| ---- | --------------------- |", + "| Boos | Array<string> |", + "", + "----------", + "", + "### AnotherInterface", + "", + "\`\`\`typescript", + "interface AnotherInterface {", + " (param1: TValue, param2: TValue): boolean;", + "}", + "\`\`\`", + "", + "#### Call", + "", + "\`\`\`typescript", + "(param1: TValue, param2: TValue): boolean", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name |", + "| ------ |", + "| TValue |", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ------ | ------ |", + "| param1 | TValue |", + "| param2 | TValue |", + "", + "**Return type**", + "", + "true | false", + "", + "----------", + "", + "### MyConstraintType", + "", + "\`\`\`typescript", + "interface MyConstraintType {", + " myProperty: string;", + "}", + "\`\`\`", + "", + "**Properties**", + "", + "| Name | Type |", + "| ---------- | ------ |", + "| myProperty | string |", + "", + "----------", + "", + "### MyDefaultType", + "", + "\`\`\`typescript", + "interface MyDefaultType extends MyConstraintType {", + " anotherProperty: number;", + "}", + "\`\`\`", + "", + "**Extends**", + "", + "[MyConstraintType][InterfaceDeclaration-4]", + "", + "**Properties**", + "", + "| Name | Type |", + "| --------------- | ------ |", + "| anotherProperty | number |", + "", + "----------", + "", + "### ObjectsInterface", + "", + "\`\`\`typescript", + "interface ObjectsInterface {", + " objectOne: Object;", + " objectTwo: Object;", + "}", + "\`\`\`", + "", + "**Properties**", + "", + "| Name | Type |", + "| --------- | ------ |", + "| objectOne | Object |", + "| objectTwo | Object |", + "", + "----------", + "", + "### InterfaceWithCall", + "", + "\`\`\`typescript", + "interface InterfaceWithCall {", + " (): { someProperty: T; };", + "}", + "\`\`\`", + "", + "#### Call", + "", + "\`\`\`typescript", + "(): { someProperty: T; }", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name |", + "| ---- |", + "| T |", + "", + "**Return type**", + "", + "{ someProperty: T; }", + "", + "----------", + "", + "### InterfaceWithConstraintType", + "", + "\`\`\`typescript", + "interface InterfaceWithConstraintType extends Dictionary {", + " someProperty: string;", + "}", + "\`\`\`", + "", + "**Extends**", + "", + "[Dictionary][InterfaceDeclaration-9]<string>", + "", + "**Properties**", + "", + "| Name | Type |", + "| ------------ | ------ |", + "| someProperty | string |", + "", + "----------", + "", + "### InterfaceWithMethod", + "", + "\`\`\`typescript", + "interface InterfaceWithMethod {", + " someMethodOne(): T;", + " someMethodTwo(): TReturn;", + "}", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name |", + "| ---- |", + "| T |", + "", + "#### Methods", + "", + "\`\`\`typescript", + "someMethodOne(): T", + "\`\`\`", + "", + "**Return type**", + "", + "T", + "", + "\`\`\`typescript", + "someMethodTwo(): TReturn", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name |", + "| ------- |", + "| TReturn |", + "", + "**Return type**", + "", + "TReturn", + "", + "----------", + "", + "### Dictionary", + "", + "\`\`\`typescript", + "interface Dictionary {", + " new (): Dictionary;", + " [key: string]: TValue;", + "}", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name |", + "| ------ |", + "| TValue |", + "", + "#### Construct", + "", + "\`\`\`typescript", + "new (): Dictionary", + "\`\`\`", + "", + "**Return type**", + "", + "[Dictionary][InterfaceDeclaration-9]<TValue>", + "", + "#### Index signatures", + "", + "\`\`\`typescript", + "[key: string]: TValue", + "\`\`\`", + "", + "* *Parameter* \`key\` - string", + "* *Type* TValue", + "", + "----------", + "", + "### MethodsInterface", + "", + "\`\`\`typescript", + "interface MethodsInterface {", + " (arg: TValue): void;", + " someMethod(): string;", + "}", + "\`\`\`", + "", + "#### Call", + "", + "\`\`\`typescript", + "(arg: TValue): void", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name |", + "| ------ |", + "| TValue |", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ---- | ------ |", + "| arg | TValue |", + "", + "**Return type**", + "", + "void", + "", + "#### Methods", + "", + "\`\`\`typescript", + "someMethod(): string", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name |", + "| ---- |", + "| T |", + "", + "**Return type**", + "", + "string", + "", + "----------", + "", + "### MonsterInterface", + "", + "Warning: Beta!", + "", + "Deprecated!", + "", + "Monster interface", + "", + "\`\`\`typescript", + "interface MonsterInterface extends ObjectsInterface {", + " new (): MonsterInterface;", + " new (someParameter: string): string;", + " (): { someProperty: T; };", + " (key?: string | undefined): { someProperty: T; };", + " (key: number): { someProperty: T; };", + " readonly [key: string]: TValue;", + " readonly objectOne: TValue;", + " objectTwo: TValue;", + "}", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name | Constraint type | Default type |", + "| ------ | --------------- | ------------ |", + "| TValue | Object | {} |", + "", + "**Extends**", + "", + "[ObjectsInterface][InterfaceDeclaration-6]", + "", + "#### Construct", + "", + "\`\`\`typescript", + "new (): MonsterInterface", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name |", + "| ---- |", + "| T |", + "", + "**Return type**", + "", + "[MonsterInterface][InterfaceDeclaration-12]<T>", + "", + "\`\`\`typescript", + "new (someParameter: string): string", + "\`\`\`", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ------------- | ------ |", + "| someParameter | string |", + "", + "**Return type**", + "", + "string", + "", + "#### Call", + "", + "\`\`\`typescript", + "(): { someProperty: T; }", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name |", + "| ---- |", + "| T |", + "", + "**Return type**", + "", + "{ someProperty: T; }", + "", + "\`\`\`typescript", + "(key?: string | undefined): { someProperty: T; }", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name |", + "| ---- |", + "| T |", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ---- | ----------------------- |", + "| key | undefined | string |", + "", + "**Return type**", + "", + "{ someProperty: T; }", + "", + "\`\`\`typescript", + "(key: number): { someProperty: T; }", + "\`\`\`", + "", + "**Type parameters**", + "", + "| Name |", + "| ---- |", + "| T |", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ---- | ------ |", + "| key | number |", + "", + "**Return type**", + "", + "{ someProperty: T; }", + "", + "#### Index signatures", + "", + "\`\`\`typescript", + "readonly [key: string]: TValue", + "\`\`\`", + "", + "* *Parameter* \`key\` - string", + "* *Type* TValue", + "", + "**Properties**", + "", + "| Name | Type |", + "| --------- | ------ |", + "| objectOne | TValue |", + "| objectTwo | TValue |", + "", + "----------", + "", + "### SomeInterface", + "", + "\`\`\`typescript", + "interface SomeInterface {", + " [key: string]: string | number;", + " [key: number]: string;", + "}", + "\`\`\`", + "", + "#### Index signatures", + "", + "\`\`\`typescript", + "[key: string]: string | number", + "\`\`\`", + "", + "* *Parameter* \`key\` - string", + "* *Type* string | number", + "", + "\`\`\`typescript", + "[key: number]: string", + "\`\`\`", + "", + "* *Parameter* \`key\` - number", + "* *Type* string", + "", + "----------", + "", + "### StringsDictionary", + "", + "\`\`\`typescript", + "interface StringsDictionary {", + " [key: string]: string;", + "}", + "\`\`\`", + "", + "#### Index signatures", + "", + "\`\`\`typescript", + "[key: string]: string", + "\`\`\`", + "", + "* *Parameter* \`key\` - string", + "* *Type* string", + "", + "----------", + "", + "### MyInterface", + "", + "\`\`\`typescript", + "interface MyInterface {", + " MyPropertyOne: string;", + " MyPropertyTwo: Object;", + " MyPropertyThree: number;", + "}", + "\`\`\`", + "", + "**Properties**", + "", + "| Name | Type |", + "| --------------- | ------ |", + "| MyPropertyOne | string |", + "| MyPropertyTwo | Object |", + "| MyPropertyThree | number |", + "", + "## Enums", + "", + "### EnumList", + "", + "Simple list.", + "", + "", + "\`\`\`typescript", + "enum EnumList {", + " FirstOption = 0,", + " SecondOption = 1,", + " ThirdOption = 2", + "}", + "\`\`\`", + "", + "**Members**", + "", + "| Name | Value | Description |", + "| ------------ | ----- | ------------------------------ |", + "| FirstOption | 0 | Description for First option. |", + "| SecondOption | 1 | Description for Second option. |", + "| ThirdOption | 2 | Description for Third option. |", + "", + "----------", + "", + "### EnumListWithNumberValues", + "", + "List with number values with no punctuation at the end of description", + "", + "", + "\`\`\`typescript", + "enum EnumListWithNumberValues {", + " FirstOption = 1,", + " SecondOption = 2,", + " ThirdOption = 3", + "}", + "\`\`\`", + "", + "**Members**", + "", + "| Name | Value |", + "| ------------ | ----- |", + "| FirstOption | 1 |", + "| SecondOption | 2 |", + "| ThirdOption | 3 |", + "", + "----------", + "", + "### EnumListWithStringValues", + "", + "Warning: Beta!", + "", + "Deprecated!", + "", + "", + "\`\`\`typescript", + "enum EnumListWithStringValues {", + " FirstOption = \\"first\\",", + " SecondOption = \\"second\\",", + " ThirdOption = \\"third\\"", + "}", + "\`\`\`", + "", + "**Members**", + "", + "| Name | Value |", + "| ------------ | -------- |", + "| FirstOption | \\"first\\" |", + "| SecondOption | \\"second\\" |", + "| ThirdOption | \\"third\\" |", + "", + "## Classes", + "", + "### [Foo][ClassDeclaration-0]", + "", + "----------", + "", + "### [World][ClassDeclaration-1]", + "", + "----------", + "", + "### [Earth][ClassDeclaration-2]", + "", + "## Variables", + "", + "### SampleConst", + "", + "\`\`\`typescript", + "const SampleConst: string;", + "\`\`\`", + "", + "**Type**", + "", + "string", + "", + "", + ], + }, + Object { + "FileLocation": "index/foo.md", + "Result": Array [ + "# Foo", + "", + "\`\`\`typescript", + "class Foo", + "\`\`\`", + "## Methods", + "", + "### HandleMessage(message)", + "", + "\`\`\`typescript", + "public HandleMessage(message: string): string", + "\`\`\`", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ------- | ------ |", + "| message | string |", + "", + "**Return type**", + "", + "string", + "", + "", + ], + }, + Object { + "FileLocation": "index/world.md", + "Result": Array [ + "# World", + "", + "\`\`\`typescript", + "class World", + "\`\`\`", + "", + ], + }, + Object { + "FileLocation": "index/earth.md", + "Result": Array [ + "# Earth", + "", + "\`\`\`typescript", + "class Earth", + "\`\`\`", + "", + ], + }, +] +`; diff --git a/packages/ts-docs-gen/tests/cases/__tests__/__snapshots__/simple-project-2.test.ts.snap b/packages/ts-docs-gen/tests/cases/__tests__/__snapshots__/simple-project-2.test.ts.snap new file mode 100644 index 00000000..376c2325 --- /dev/null +++ b/packages/ts-docs-gen/tests/cases/__tests__/__snapshots__/simple-project-2.test.ts.snap @@ -0,0 +1,107 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`simple-project-2 1`] = ` +Array [ + Object { + "FileLocation": "index.md", + "Result": Array [ + "[ClassDeclaration-0]: index/foo.md#foo", + "[ClassDeclaration-1]: index/foostart.md#foostart", + "# index", + "", + "## Classes", + "", + "### [Foo][ClassDeclaration-0]", + "", + "----------", + "", + "### [FooStart][ClassDeclaration-1]", + "", + "", + ], + }, + Object { + "FileLocation": "index/foo.md", + "Result": Array [ + "# Foo", + "", + "\`\`\`typescript", + "class Foo", + "\`\`\`", + "## Methods", + "", + "### GetMessage(message)", + "", + "\`\`\`typescript", + "public GetMessage(message: string): string", + "\`\`\`", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ------- | ------ |", + "| message | string |", + "", + "**Return type**", + "", + "string", + "", + "## Properties", + "", + "### defaultMessage", + "", + "\`\`\`typescript", + "private readonly defaultMessage: string;", + "\`\`\`", + "", + "**Type**", + "", + "string", + "", + "", + ], + }, + Object { + "FileLocation": "index/foostart.md", + "Result": Array [ + "# FooStart", + "", + "\`\`\`typescript", + "class FooStart", + "\`\`\`", + "## Methods", + "", + "### HandleMessage(message)", + "", + "\`\`\`typescript", + "public HandleMessage(message: string): string", + "\`\`\`", + "", + "**Parameters**", + "", + "| Name | Type |", + "| ------- | ------ |", + "| message | string |", + "", + "**Return type**", + "", + "string", + "", + "", + ], + }, + Object { + "FileLocation": "foo.md", + "Result": Array [ + "[ClassDeclaration-0]: index/foo.md#foo", + "# foo", + "", + "## Classes", + "", + "### [Foo][ClassDeclaration-0]", + "", + "", + ], + }, +] +`; diff --git a/packages/ts-docs-gen/tests/cases/simple-project-1/index.ts b/packages/ts-docs-gen/tests/cases/simple-project-1/index.ts new file mode 100644 index 00000000..4d7dd18d --- /dev/null +++ b/packages/ts-docs-gen/tests/cases/simple-project-1/index.ts @@ -0,0 +1,238 @@ +// #region Interfaces +export interface ExtendedBar extends FooInterface, Boo { + OtherStuff: string[]; +} + +export interface FooInterface { + Name: string; + Surname: string; + Type: TType; +} + +export interface Boo { + Boos: string[]; +} + +export interface AnotherInterface { + (param1: TValue, param2: TValue): boolean; +} + +export interface MyConstraintType { + myProperty: string; +} + +export interface MyDefaultType extends MyConstraintType { + anotherProperty: number; +} + +export interface ObjectsInterface { + objectOne: Object; + objectTwo: Object; +} + +export interface InterfaceWithCall { + (): { someProperty: T }; +} + +export interface InterfaceWithConstraintType extends Dictionary { + someProperty: string; +} + +export interface InterfaceWithMethod { + someMethodOne(): T; + someMethodTwo(): TReturn; +} + +export interface Dictionary { + new(): Dictionary; + [key: string]: TValue; +} + +export interface MethodsInterface { + someMethod(): string; + (arg: TValue): void; +} + +/** + * Monster interface + * @beta + * @deprecated + */ +export interface MonsterInterface extends ObjectsInterface { + new (): MonsterInterface; + new(someParameter: string): string; + + readonly [key: string]: TValue; + + (): { someProperty: T }; + (key?: string): { someProperty: T }; + (key: number): { someProperty: T }; + + readonly objectOne: TValue; + objectTwo: TValue; +} + +export interface SomeInterface { + [key: string]: string | number; + [key: number]: string; +} + +export interface StringsDictionary { + [key: string]: string; +} + +export interface MyInterface { + MyPropertyOne: string; + MyPropertyTwo: Object; + MyPropertyThree: number; +} +// #endregion Interfaces + +// #region Enums +/** + * Simple list. + */ +export enum EnumList { + /** + * Description for First option. + */ + FirstOption, + /** + * Description for Second option. + */ + SecondOption, + /** + * Description for Third option. + */ + ThirdOption +} + +/** + * List with number values with no punctuation at the end of description + */ +export enum EnumListWithNumberValues { + FirstOption = 1, + SecondOption = 2, + ThirdOption = 3 +} + +/** + * @beta + * @deprecated + */ +export enum EnumListWithStringValues { + FirstOption = "first", + SecondOption = "second", + ThirdOption = "third" +} + +// #endregion Enums + +export const SampleConst: string = "sample-const"; + +export class Foo { + public HandleMessage(message: string): string { + return message; + } +} + +export class World { } +export class Earth { } + +// #region Functions + +export function AnotherFoo(parameter1: string, parameter2: Promise): string { + return "bar"; +} + +export async function GetFoo(): Promise { + return; +} + +export function FunctionWithOneParameter(parameter: string): void { + return; +} + +export function FunctionWithNoParameters(): void { + return; +} + +export function FunctionWithMultipleParameters(parameter1: string, parameter2: number): void { + return; +} + +/** + * Some general comment about Bar function. + * + * @beta Some comment on beta. + * @deprecated + */ +export function Bar(parameter1: string, parameter2: number): string { + return "bar"; +} + +/** + * Comment on Function with multiple type parameters. + * + * @template T Parameter T comment + * @template P Parameter P comment + * @param parameter1 Parameter one comment + * @param parameter2 Parameter two comment + * @returns Return type comment + */ +export function FunctionWithMultipleTypeParameters(parameter1: T, parameter2: P): string { + return "bar"; +} + +/** + * Some general comment about Function with type parameter default function. + */ +export function FunctionWithTypeParameterDefault(parameter1: string, parameter2: T): string { + return "bar"; +} + +/** + * Some general comment about AnotherBar function. + */ +export function FunctionWithTypeParameterConstraint(parameter1: string, parameter2: T): string { + return "bar"; +} + +export function FunctionWithoutReturnType(parameter1: string, parameter2: Promise): string { + return "bar"; +} + +export function FunctionWithGenericReturnType(): string[] { + return []; +} + +export function FunctionWithPrimitiveReturnType(): boolean { + return true; +} + +export function FunctionWithUnionReturnType(): "something" | "nothing" { + return "nothing"; +} + +export function FunctionWithIntersectionReturnType(): Earth & World { + return {}; +} + +/** + * Function with TypeParameter as TypeLiteral. + */ +export function MyFunction(): T { + return { + myProperty: "sampleString" + } as T; +} + +export function FunctionWithInitializedNumberParameter(someParameter: number = 12): number { + return someParameter; +} + +export function FunctionWithInitializedStringParameter(someParameter: string = "12"): string { + return someParameter; +} + +// #endregion Functions diff --git a/packages/ts-docs-gen/tests/cases/simple-project-1/package.json b/packages/ts-docs-gen/tests/cases/simple-project-1/package.json new file mode 100644 index 00000000..6d2e250d --- /dev/null +++ b/packages/ts-docs-gen/tests/cases/simple-project-1/package.json @@ -0,0 +1,13 @@ +{ + "name": "simple-project-1", + "private": true, + "version": "1.0.0", + "description": "", + "main": "index.js", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "keywords": [], + "author": "", + "license": "ISC" +} diff --git a/packages/ts-docs-gen/tests/cases/simple-project-1/test-config.json b/packages/ts-docs-gen/tests/cases/simple-project-1/test-config.json new file mode 100644 index 00000000..a058bc3b --- /dev/null +++ b/packages/ts-docs-gen/tests/cases/simple-project-1/test-config.json @@ -0,0 +1,5 @@ +{ + "EntryFiles": [ + "./index.ts" + ] +} diff --git a/packages/ts-docs-gen/tests/cases/simple-project-1/tsconfig.json b/packages/ts-docs-gen/tests/cases/simple-project-1/tsconfig.json new file mode 100644 index 00000000..433fcc04 --- /dev/null +++ b/packages/ts-docs-gen/tests/cases/simple-project-1/tsconfig.json @@ -0,0 +1,32 @@ +{ + "compilerOptions": { + "module": "commonjs", + "target": "es6", + "removeComments": false, + "outDir": "dist", + "rootDir": "src", + "inlineSourceMap": true, + "inlineSources": true, + "skipDefaultLibCheck": true, + "declaration": true, + "pretty": true, + "strict": true, + "forceConsistentCasingInFileNames": true, + "lib": [ + "es6" + ], + "types": [ + "node" + ], + "typeRoots": [ + "./node_modules/@types" + ] + }, + "exclude": [ + "node_modules", + "dist", + "@types", + "tests", + "examples" + ] +} diff --git a/packages/ts-docs-gen/tests/cases/simple-project-2/foo.ts b/packages/ts-docs-gen/tests/cases/simple-project-2/foo.ts new file mode 100644 index 00000000..58ed1b72 --- /dev/null +++ b/packages/ts-docs-gen/tests/cases/simple-project-2/foo.ts @@ -0,0 +1,7 @@ +export class Foo { + public GetMessage(message: string): string { + return this.defaultMessage; + } + + private readonly defaultMessage: string = "It's a default message."; +} diff --git a/packages/ts-docs-gen/tests/cases/simple-project-2/index.ts b/packages/ts-docs-gen/tests/cases/simple-project-2/index.ts new file mode 100644 index 00000000..1c5e60c1 --- /dev/null +++ b/packages/ts-docs-gen/tests/cases/simple-project-2/index.ts @@ -0,0 +1,7 @@ +export { Foo } from "./foo"; + +export class FooStart { + public HandleMessage(message: string): string { + return message; + } +} diff --git a/packages/ts-docs-gen/tests/cases/simple-project-2/package.json b/packages/ts-docs-gen/tests/cases/simple-project-2/package.json new file mode 100644 index 00000000..11443f1e --- /dev/null +++ b/packages/ts-docs-gen/tests/cases/simple-project-2/package.json @@ -0,0 +1,13 @@ +{ + "name": "simple-project-2", + "private": true, + "version": "1.0.0", + "description": "", + "main": "index.js", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "keywords": [], + "author": "", + "license": "ISC" +} diff --git a/packages/ts-docs-gen/tests/cases/simple-project-2/test-config.json b/packages/ts-docs-gen/tests/cases/simple-project-2/test-config.json new file mode 100644 index 00000000..182bf979 --- /dev/null +++ b/packages/ts-docs-gen/tests/cases/simple-project-2/test-config.json @@ -0,0 +1,6 @@ +{ + "EntryFiles": [ + "./index.ts", + "./foo.ts" + ] +} diff --git a/packages/ts-docs-gen/tests/cases/simple-project-2/tsconfig.json b/packages/ts-docs-gen/tests/cases/simple-project-2/tsconfig.json new file mode 100644 index 00000000..433fcc04 --- /dev/null +++ b/packages/ts-docs-gen/tests/cases/simple-project-2/tsconfig.json @@ -0,0 +1,32 @@ +{ + "compilerOptions": { + "module": "commonjs", + "target": "es6", + "removeComments": false, + "outDir": "dist", + "rootDir": "src", + "inlineSourceMap": true, + "inlineSources": true, + "skipDefaultLibCheck": true, + "declaration": true, + "pretty": true, + "strict": true, + "forceConsistentCasingInFileNames": true, + "lib": [ + "es6" + ], + "types": [ + "node" + ], + "typeRoots": [ + "./node_modules/@types" + ] + }, + "exclude": [ + "node_modules", + "dist", + "@types", + "tests", + "examples" + ] +} diff --git a/packages/ts-docs-gen/tests/default.test.tpl b/packages/ts-docs-gen/tests/default.test.tpl new file mode 100644 index 00000000..17493e2b --- /dev/null +++ b/packages/ts-docs-gen/tests/default.test.tpl @@ -0,0 +1,20 @@ +import { Generator } from "@src/generator"; +import { GeneratorConfigurationBuilder } from "@src/builders/generator-configuration-builder"; + +test("{{caseName}}", async done => { + const projectDirectory = "{{projectDirectory}}"; + const testConfig = {{{json testConfig}}}; + const entryFiles = testConfig.EntryFiles; + + try { + const configuration = await new GeneratorConfigurationBuilder(projectDirectory) + .Build(entryFiles); + + const generator = new Generator(configuration); + + expect(generator.OutputData).toMatchSnapshot(); + done(); + } catch (error) { + done.fail(error); + } +}); diff --git a/packages/ts-docs-gen/tests/tsconfig.json b/packages/ts-docs-gen/tests/tsconfig.json new file mode 100644 index 00000000..48e57492 --- /dev/null +++ b/packages/ts-docs-gen/tests/tsconfig.json @@ -0,0 +1,34 @@ +{ + "compilerOptions": { + "module": "commonjs", + "target": "es6", + "removeComments": false, + "sourceMap": false, + "skipDefaultLibCheck": true, + "pretty": true, + "noEmit": true, + "experimentalDecorators": false, + "baseUrl": "./", + "typeRoots": [ + "../" + ], + "types": [ + "jest", + "typescript", + "node" + ], + "lib": [ + "es6", + "dom" + ], + "paths": { + "@src/*": [ + "../src/*" + ] + }, + "rootDirs": [ + "./", + "../src" + ] + } +} diff --git a/packages/ts-docs-gen/tsconfig.json b/packages/ts-docs-gen/tsconfig.json new file mode 100644 index 00000000..f8eb4b11 --- /dev/null +++ b/packages/ts-docs-gen/tsconfig.json @@ -0,0 +1,36 @@ +{ + "compilerOptions": { + "module": "commonjs", + "target": "es6", + "removeComments": false, + "outDir": "dist", + "rootDir": "src", + "inlineSourceMap": true, + "inlineSources": true, + "skipDefaultLibCheck": true, + "declaration": true, + "pretty": true, + "strict": true, + "forceConsistentCasingInFileNames": true, + "noUnusedLocals": true, + "lib": [ + "es6", + "es2017.object" + ], + "types": [ + "node" + ], + "typeRoots": [ + "./node_modules/@types" + ] + }, + "exclude": [ + "node_modules", + "dist", + "@types", + "tests", + "examples", + "_src", + "__tests__" + ] +} diff --git a/packages/ts-docs-gen/tslint.json b/packages/ts-docs-gen/tslint.json new file mode 100644 index 00000000..85c41b83 --- /dev/null +++ b/packages/ts-docs-gen/tslint.json @@ -0,0 +1,3 @@ +{ + "extends": "simplr-tslint" +} diff --git a/rush.json b/rush.json new file mode 100644 index 00000000..2b0a59a5 --- /dev/null +++ b/rush.json @@ -0,0 +1,17 @@ +{ + "$schema": "./common/schemas/rush.schema.json", + "npmVersion": "5.3.0", + "rushVersion": "4.0.1", + "projects": [ + { + "packageName": "ts-docs-gen", + "projectFolder": "packages/ts-docs-gen", + "shouldPublish": false + }, + { + "packageName": "test-generator-cli", + "projectFolder": "tools/test-generator-cli", + "shouldPublish": false + } + ] +} diff --git a/tools/test-generator-cli/package.json b/tools/test-generator-cli/package.json new file mode 100644 index 00000000..80e24bc6 --- /dev/null +++ b/tools/test-generator-cli/package.json @@ -0,0 +1,32 @@ +{ + "name": "test-generator-cli", + "private": true, + "version": "0.1.0", + "description": "Generating tests.", + "main": "index.js", + "scripts": { + "build": "tsc -p .", + "watch": "tsc -w", + "pretest": "npm run build -- --noEmit", + "test": "npm run tslint", + "test-ci": "npm test", + "tslint": "tslint --project . --config ./tslint.json && echo Successfully passed tslint test." + }, + "keywords": [], + "author": "simplrjs (https://github.com/simplrjs)", + "dependencies": { + "@types/fs-extra": "^4.0.5", + "@types/handlebars": "^4.0.36", + "@types/yargs": "^10.0.0", + "fast-glob": "^1.0.1", + "fs-extra": "^4.0.2", + "handlebars": "^4.0.11", + "simplr-logger": "^1.0.0", + "typescript": "^2.6.2", + "yargs": "^10.0.3" + }, + "devDependencies": { + "simplr-tslint": "0.0.1", + "tslint": "^5.8.0" + } +} diff --git a/tools/test-generator-cli/src/cli-arguments.ts b/tools/test-generator-cli/src/cli-arguments.ts new file mode 100644 index 00000000..b37ea4b2 --- /dev/null +++ b/tools/test-generator-cli/src/cli-arguments.ts @@ -0,0 +1,21 @@ +import * as yargs from "yargs"; + +import { GetVersion } from "./cli-helpers"; +import { CLIArgumentsObject } from "./cli-contracts"; + +/** + * Handles all CLI commands and arguments. + */ +export const CLIHandler = yargs + .showHelpOnFail(true) + .help("h", "Show help") + .alias("h", "help") + .version(`Current version: ${GetVersion()}`) + .alias("v", "version") + // CLI options + .option("project", { + describe: "Project directory path.", + type: "string" + }) + .alias("p", "project") + .argv as CLIArgumentsObject; diff --git a/tools/test-generator-cli/src/cli-contracts.ts b/tools/test-generator-cli/src/cli-contracts.ts new file mode 100644 index 00000000..7b33725c --- /dev/null +++ b/tools/test-generator-cli/src/cli-contracts.ts @@ -0,0 +1,20 @@ +import { Arguments } from "yargs"; + +/** + * Base properties of `package.json`. + */ +export interface BasePackage { + name: string; + version: string; + description?: string; + main: string; + author?: string; + license?: string; +} + +/** + * Argument of CLI. + */ +export interface CLIArgumentsObject extends Arguments { + path?: string; +} diff --git a/tools/test-generator-cli/src/cli-helpers.ts b/tools/test-generator-cli/src/cli-helpers.ts new file mode 100644 index 00000000..cf825bb4 --- /dev/null +++ b/tools/test-generator-cli/src/cli-helpers.ts @@ -0,0 +1,21 @@ +import * as fs from "fs-extra"; +import * as path from "path"; + +import { BasePackage } from "./cli-contracts"; + +/** + * Path from current file to a `package.json`. + */ +const PACKAGE_JSON_PATH = "../package.json"; + +/** + * Object of `package.json`. + */ +export const PACKAGE_JSON = fs.readJSONSync(path.join(__dirname, PACKAGE_JSON_PATH)) as BasePackage; + +/** + * Get version string from `package.json`. + */ +export function GetVersion(): string { + return PACKAGE_JSON.version; +} diff --git a/tools/test-generator-cli/src/index.ts b/tools/test-generator-cli/src/index.ts new file mode 100644 index 00000000..73d24417 --- /dev/null +++ b/tools/test-generator-cli/src/index.ts @@ -0,0 +1,39 @@ +import * as fs from "fs-extra"; +import * as path from "path"; + +import { Logger } from "./utils/logger"; +import { TestsGenerator } from "./tests-generator"; +import { FixSep, TESTS_DIR_NAME, CASES_DIR_NAME } from "./tests-helpers"; +import { TestsCleanup } from "./tests-cleanup"; +import { CLIHandler } from "./cli-arguments"; +import { CLIArgumentsObject } from "./cli-contracts"; + +async function StartWatcher(testsCasesPath: string): Promise { + return fs.watch(`${testsCasesPath}/`, async (event, fileName) => { + if (fileName.indexOf(TESTS_DIR_NAME) === -1) { + Logger.Info(`Test file was changed in "${testsCasesPath}/${fileName}".`); + const startBuild = Logger.Info(`Generating tests for "${testsCasesPath}"...`); + await TestsGenerator(testsCasesPath); + Logger.Debug(`Generated tests after ${(Date.now() - startBuild)}ms`); + } + }); +} + +(async (argumentsObject: CLIArgumentsObject) => { + const cwd = argumentsObject.path || process.cwd(); + const testsCasesPath = FixSep(path.join(cwd, TESTS_DIR_NAME, CASES_DIR_NAME)); + + Logger.Info("Starting test generator..."); + const startRemove = Logger.Info(`Removing old tests from "${testsCasesPath}"...`); + await TestsCleanup(testsCasesPath); + Logger.Debug(`Removed old tests after ${(Date.now() - startRemove)}ms`); + + const startBuild = Logger.Info(`Generating tests for "${testsCasesPath}"...`); + await TestsGenerator(testsCasesPath); + Logger.Debug(`Generated tests after ${(Date.now() - startBuild)}ms`); + + if (process.argv.indexOf("--watchAll") !== -1) { + Logger.Info(`Started watching "${testsCasesPath}" tests.`); + StartWatcher(testsCasesPath); + } +})(CLIHandler); diff --git a/tools/test-generator-cli/src/tests-cleanup.ts b/tools/test-generator-cli/src/tests-cleanup.ts new file mode 100644 index 00000000..1fde9c3a --- /dev/null +++ b/tools/test-generator-cli/src/tests-cleanup.ts @@ -0,0 +1,22 @@ +import * as fs from "fs-extra"; +import * as path from "path"; +import fastGlob from "fast-glob"; + +import { + GENERATED_TESTS_DIR_NAME, + TESTS_SNAPSHOTS_DIR_NAME, + FixSep +} from "./tests-helpers"; + +export async function TestsCleanup(testsCasesPath: string): Promise { + const generatedTestsDirPath = FixSep(path.join(testsCasesPath, GENERATED_TESTS_DIR_NAME)); + + const oldTestFiles = await fastGlob(`${generatedTestsDirPath}/**/*`, { + onlyFiles: true, + ignore: [`**/${TESTS_SNAPSHOTS_DIR_NAME}/**`] + }); + + for (const pathname of oldTestFiles) { + await fs.remove(pathname); + } +} diff --git a/tools/test-generator-cli/src/tests-generator.ts b/tools/test-generator-cli/src/tests-generator.ts new file mode 100644 index 00000000..1eaa752e --- /dev/null +++ b/tools/test-generator-cli/src/tests-generator.ts @@ -0,0 +1,67 @@ +import * as path from "path"; +import * as fs from "fs-extra"; +import fastGlob from "fast-glob"; +import * as handlebars from "handlebars"; + +import { + FixSep, + GENERATED_TESTS_DIR_NAME, + TESTS_CONFIG_FILE_NAME, + DEFAULT_TEMPLATE_FILE_NAME, + CASE_TEMPLATE_FILE_NAME, + RegisterJSONStringifyHandlebarHelper +} from "./tests-helpers"; +import { Logger } from "./utils/logger"; + +export interface Configuration { + EntryFiles: string[]; +} + +export async function TestsGenerator(testsCasesPath: string): Promise { + const defaultTemplatePath = FixSep(path.join(testsCasesPath, "..", DEFAULT_TEMPLATE_FILE_NAME)); + if (!await fs.pathExists(defaultTemplatePath)) { + Logger.Error(`Not found package default template. Expected file location: "${defaultTemplatePath}"`); + return; + } + + const casesDirPaths = await fastGlob( + [ + `${testsCasesPath}/*` + ], + { + onlyDirs: true, + ignore: [`**/${GENERATED_TESTS_DIR_NAME}/**`] + }); + + const targetDirectory = path.join(testsCasesPath, GENERATED_TESTS_DIR_NAME); + await fs.ensureDir(targetDirectory); + + RegisterJSONStringifyHandlebarHelper(); + + for (const caseDirPath of casesDirPaths) { + const { name } = path.parse(caseDirPath); + + const caseTemplatePath = FixSep(path.join(caseDirPath, CASE_TEMPLATE_FILE_NAME)); + let templatePath: string; + if (await fs.pathExists(caseTemplatePath)) { + templatePath = caseTemplatePath; + } else { + templatePath = defaultTemplatePath; + } + + const testConfigPath = FixSep(path.join(caseDirPath, TESTS_CONFIG_FILE_NAME)); + const testConfig = await fs.readJSON(testConfigPath) as Configuration; + + const source = await fs.readFile(templatePath, "utf8"); + const template = handlebars.compile(source); + const data = { + "caseName": name, + "projectDirectory": caseDirPath, + "testConfig": testConfig + }; + const testDescribe = template(data); + + const targetFilePathName = path.join(targetDirectory, `${name}.test.ts`); + await fs.writeFile(targetFilePathName, testDescribe); + } +} diff --git a/tools/test-generator-cli/src/tests-helpers.ts b/tools/test-generator-cli/src/tests-helpers.ts new file mode 100644 index 00000000..500b2a71 --- /dev/null +++ b/tools/test-generator-cli/src/tests-helpers.ts @@ -0,0 +1,23 @@ +import * as path from "path"; +import * as handlebars from "handlebars"; + +export function FixSep(pathname: string): string { + return pathname.split(path.sep).join("/"); +} + +export function RegisterJSONStringifyHandlebarHelper(): void { + handlebars.registerHelper("json", (value: any) => + new handlebars.SafeString( + JSON.stringify(value) + )); +} + +export const TESTS_DIR_NAME = "tests"; +export const CASES_DIR_NAME = "cases"; + +export const GENERATED_TESTS_DIR_NAME = "__tests__"; +export const TESTS_SNAPSHOTS_DIR_NAME = "__snapshots__"; + +export const TESTS_CONFIG_FILE_NAME = "test-config.json"; +export const DEFAULT_TEMPLATE_FILE_NAME = "default.test.tpl"; +export const CASE_TEMPLATE_FILE_NAME = "case.test.tpl"; diff --git a/tools/test-generator-cli/src/utils/logger.ts b/tools/test-generator-cli/src/utils/logger.ts new file mode 100644 index 00000000..55b1a36d --- /dev/null +++ b/tools/test-generator-cli/src/utils/logger.ts @@ -0,0 +1,7 @@ +import { LoggerBuilder, LoggerConfigurationBuilder, LogLevel } from "simplr-logger"; + +const LoggerConfiguration = new LoggerConfigurationBuilder() + .SetDefaultLogLevel(LogLevel.Trace) + .Build(); + +export const Logger = new LoggerBuilder(LoggerConfiguration); diff --git a/tools/test-generator-cli/tsconfig.json b/tools/test-generator-cli/tsconfig.json new file mode 100644 index 00000000..2fe54924 --- /dev/null +++ b/tools/test-generator-cli/tsconfig.json @@ -0,0 +1,33 @@ +{ + "compilerOptions": { + "module": "commonjs", + "target": "es6", + "removeComments": false, + "outDir": "dist", + "rootDir": "src", + "inlineSourceMap": true, + "inlineSources": true, + "skipDefaultLibCheck": true, + "declaration": true, + "pretty": true, + "strict": true, + "forceConsistentCasingInFileNames": true, + "noUnusedLocals": true, + "skipLibCheck": true, + "lib": [ + "es6", + "es2017.object" + ], + "types": [ + "node" + ], + "typeRoots": [ + "./node_modules/@types" + ] + }, + "exclude": [ + "node_modules", + "dist", + "@types" + ] +} diff --git a/tools/test-generator-cli/tslint.json b/tools/test-generator-cli/tslint.json new file mode 100644 index 00000000..3385cef2 --- /dev/null +++ b/tools/test-generator-cli/tslint.json @@ -0,0 +1,3 @@ +{ + "extends": "simplr-tslint" +}