diff --git a/package-lock.json b/package-lock.json index 0f1fb89ba..bf848c51c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -5,25 +5,24 @@ "requires": true, "dependencies": { "@babel/code-frame": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.0.0.tgz", - "integrity": "sha512-OfC2uemaknXr87bdLUkWog7nYuliM9Ij5HUcajsVcMCpQrcLmtxRbVFTIqmcSkSeYRBFBRxs2FiUqFJDLdiebA==", + "version": "7.5.5", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.5.5.tgz", + "integrity": "sha512-27d4lZoomVyo51VegxI20xZPuSHusqbQag/ztrBC7wegWoQ1nLREPVSKSW8byhTlzTKyNE4ifaTA6lCp7JjpFw==", "dev": true, "requires": { "@babel/highlight": "^7.0.0" } }, "@babel/generator": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.4.4.tgz", - "integrity": "sha512-53UOLK6TVNqKxf7RUh8NE851EHRxOOeVXKbK2bivdb+iziMyk03Sr4eaE9OELCbyZAAafAKPDwF2TPUES5QbxQ==", + "version": "7.6.4", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.6.4.tgz", + "integrity": "sha512-jsBuXkFoZxk0yWLyGI9llT9oiQ2FeTASmRFE32U+aaDTfoE92t78eroO7PTpU/OrYq38hlcDM6vbfLDaOLy+7w==", "dev": true, "requires": { - "@babel/types": "^7.4.4", + "@babel/types": "^7.6.3", "jsesc": "^2.5.1", - "lodash": "^4.17.11", - "source-map": "^0.5.0", - "trim-right": "^1.0.1" + "lodash": "^4.17.13", + "source-map": "^0.5.0" }, "dependencies": { "source-map": { @@ -64,9 +63,9 @@ } }, "@babel/highlight": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.0.0.tgz", - "integrity": "sha512-UFMC4ZeFC48Tpvj7C8UgLvtkaUuovQX+5xNWrsIoMG8o2z+XFKjKaN9iVmS84dPwVN00W4wPmqvYoZF3EGAsfw==", + "version": "7.5.0", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.5.0.tgz", + "integrity": "sha512-7dV4eu9gBxoM0dAnj/BCFDW9LFU0zvTrkq0ugM7pnHEgguOEeOz1so2ZghEdzviYzQEED0r4EAgpsBChKy1TRQ==", "dev": true, "requires": { "chalk": "^2.0.0", @@ -75,37 +74,37 @@ } }, "@babel/parser": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.4.4.tgz", - "integrity": "sha512-5pCS4mOsL+ANsFZGdvNLybx4wtqAZJ0MJjMHxvzI3bvIsz6sQvzW8XX92EYIkiPtIvcfG3Aj+Ir5VNyjnZhP7w==", + "version": "7.6.4", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.6.4.tgz", + "integrity": "sha512-D8RHPW5qd0Vbyo3qb+YjO5nvUVRTXFLQ/FsDxJU2Nqz4uB5EnUN0ZQSEYpvTIbRuttig1XbHWU5oMeQwQSAA+A==", "dev": true }, "@babel/template": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.4.4.tgz", - "integrity": "sha512-CiGzLN9KgAvgZsnivND7rkA+AeJ9JB0ciPOD4U59GKbQP2iQl+olF1l76kJOupqidozfZ32ghwBEJDhnk9MEcw==", + "version": "7.6.0", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.6.0.tgz", + "integrity": "sha512-5AEH2EXD8euCk446b7edmgFdub/qfH1SN6Nii3+fyXP807QRx9Q73A2N5hNwRRslC2H9sNzaFhsPubkS4L8oNQ==", "dev": true, "requires": { "@babel/code-frame": "^7.0.0", - "@babel/parser": "^7.4.4", - "@babel/types": "^7.4.4" + "@babel/parser": "^7.6.0", + "@babel/types": "^7.6.0" } }, "@babel/traverse": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.4.4.tgz", - "integrity": "sha512-Gw6qqkw/e6AGzlyj9KnkabJX7VcubqPtkUQVAwkc0wUMldr3A/hezNB3Rc5eIvId95iSGkGIOe5hh1kMKf951A==", + "version": "7.6.3", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.6.3.tgz", + "integrity": "sha512-unn7P4LGsijIxaAJo/wpoU11zN+2IaClkQAxcJWBNCMS6cmVh802IyLHNkAjQ0iYnRS3nnxk5O3fuXW28IMxTw==", "dev": true, "requires": { - "@babel/code-frame": "^7.0.0", - "@babel/generator": "^7.4.4", + "@babel/code-frame": "^7.5.5", + "@babel/generator": "^7.6.3", "@babel/helper-function-name": "^7.1.0", "@babel/helper-split-export-declaration": "^7.4.4", - "@babel/parser": "^7.4.4", - "@babel/types": "^7.4.4", + "@babel/parser": "^7.6.3", + "@babel/types": "^7.6.3", "debug": "^4.1.0", "globals": "^11.1.0", - "lodash": "^4.17.11" + "lodash": "^4.17.13" }, "dependencies": { "debug": { @@ -120,13 +119,13 @@ } }, "@babel/types": { - "version": "7.4.4", - "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.4.4.tgz", - "integrity": "sha512-dOllgYdnEFOebhkKCjzSVFqw/PmmB8pH6RGOWkY4GsboQNd47b1fBThBSwlHAq9alF9vc1M3+6oqR47R50L0tQ==", + "version": "7.6.3", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.6.3.tgz", + "integrity": "sha512-CqbcpTxMcpuQTMhjI37ZHVgjBkysg5icREQIEZ0eG1yCNwg3oy+5AaLiOKmjsCj6nqOsa6Hf0ObjRVwokb7srA==", "dev": true, "requires": { "esutils": "^2.0.2", - "lodash": "^4.17.11", + "lodash": "^4.17.13", "to-fast-properties": "^2.0.0" } }, @@ -137,9 +136,9 @@ "dev": true }, "@types/fs-extra": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/@types/fs-extra/-/fs-extra-8.0.0.tgz", - "integrity": "sha512-bCtL5v9zdbQW86yexOlXWTEGvLNqWxMFyi7gQA7Gcthbezr2cPSOb8SkESVKA937QD5cIwOFLDFt0MQoXOEr9Q==", + "version": "8.0.1", + "resolved": "https://registry.npmjs.org/@types/fs-extra/-/fs-extra-8.0.1.tgz", + "integrity": "sha512-J00cVDALmi/hJOYsunyT52Hva5TnJeKP5yd1r+mH/ZU0mbYZflR0Z5kw5kITtKTRYMhm1JMClOFYdHnQszEvqw==", "dev": true, "requires": { "@types/node": "*" @@ -186,15 +185,15 @@ "dev": true }, "@types/node": { - "version": "12.7.12", - "resolved": "https://registry.npmjs.org/@types/node/-/node-12.7.12.tgz", - "integrity": "sha512-KPYGmfD0/b1eXurQ59fXD1GBzhSQfz6/lKBxkaHX9dKTzjXbK68Zt7yGUxUsCS1jeTy/8aL+d9JEr+S54mpkWQ==", + "version": "12.12.5", + "resolved": "https://registry.npmjs.org/@types/node/-/node-12.12.5.tgz", + "integrity": "sha512-KEjODidV4XYUlJBF3XdjSH5FWoMCtO0utnhtdLf1AgeuZLOrRbvmU/gaRCVg7ZaQDjVf3l84egiY0mRNe5xE4A==", "dev": true }, "@types/shelljs": { - "version": "0.8.5", - "resolved": "https://registry.npmjs.org/@types/shelljs/-/shelljs-0.8.5.tgz", - "integrity": "sha512-bZgjwIWu9gHCjirKJoOlLzGi5N0QgZ5t7EXEuoqyWCHTuSddURXo3FOBYDyRPNOWzZ6NbkLvZnVkn483Y/tvcQ==", + "version": "0.8.6", + "resolved": "https://registry.npmjs.org/@types/shelljs/-/shelljs-0.8.6.tgz", + "integrity": "sha512-svx2eQS268awlppL/P8wgDLBrsDXdKznABHJcuqXyWpSKJgE1s2clXlBvAwbO/lehTmG06NtEWJRkAk4tAgenA==", "dev": true, "requires": { "@types/glob": "*", @@ -325,22 +324,44 @@ } }, "cliui": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz", - "integrity": "sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ==", + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", + "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", "dev": true, "requires": { - "string-width": "^2.1.1", - "strip-ansi": "^4.0.0", - "wrap-ansi": "^2.0.0" + "string-width": "^3.1.0", + "strip-ansi": "^5.2.0", + "wrap-ansi": "^5.1.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } } }, - "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=", - "dev": true - }, "color-convert": { "version": "1.9.3", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", @@ -357,9 +378,9 @@ "dev": true }, "commander": { - "version": "2.20.0", - "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.0.tgz", - "integrity": "sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ==" + "version": "2.20.3", + "resolved": "https://registry.npmjs.org/commander/-/commander-2.20.3.tgz", + "integrity": "sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==" }, "commondir": { "version": "1.0.1", @@ -395,15 +416,12 @@ } }, "cross-spawn": { - "version": "6.0.5", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", - "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-4.0.2.tgz", + "integrity": "sha1-e5JHYhwjrf3ThWAEqCPL45dCTUE=", "dev": true, "requires": { - "nice-try": "^1.0.4", - "path-key": "^2.0.1", - "semver": "^5.5.0", - "shebang-command": "^1.2.0", + "lru-cache": "^4.0.1", "which": "^1.2.9" } }, @@ -452,15 +470,6 @@ "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", "dev": true }, - "end-of-stream": { - "version": "1.4.1", - "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.1.tgz", - "integrity": "sha512-1MkrZNvWTKCaigbn+W15elq2BB/L22nqrSY5DKlo3X6+vclJm8Bb5djXJBmEX6fS3+zCh/F4VBK5Z2KxJt4s2Q==", - "dev": true, - "requires": { - "once": "^1.4.0" - } - }, "error-ex": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", @@ -471,9 +480,9 @@ } }, "es-abstract": { - "version": "1.15.0", - "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.15.0.tgz", - "integrity": "sha512-bhkEqWJ2t2lMeaJDuk7okMkJWI/yqgH/EoGwpcvv0XW9RWQsRspI4wt6xuyuvMvvQE3gg/D9HXppgk21w78GyQ==", + "version": "1.16.0", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.16.0.tgz", + "integrity": "sha512-xdQnfykZ9JMEiasTAJZJdMWCQ1Vm00NBw79/AWi7ELfZuuPCSOMDZbT9mkOfSctVtfhb+sAAzrm+j//GjjLHLg==", "dev": true, "requires": { "es-to-primitive": "^1.2.0", @@ -518,26 +527,11 @@ "dev": true }, "esutils": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.2.tgz", - "integrity": "sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs=", + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", + "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", "dev": true }, - "execa": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/execa/-/execa-1.0.0.tgz", - "integrity": "sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA==", - "dev": true, - "requires": { - "cross-spawn": "^6.0.0", - "get-stream": "^4.0.0", - "is-stream": "^1.1.0", - "npm-run-path": "^2.0.0", - "p-finally": "^1.0.0", - "signal-exit": "^3.0.0", - "strip-eof": "^1.0.0" - } - }, "find-cache-dir": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/find-cache-dir/-/find-cache-dir-2.1.0.tgz", @@ -575,18 +569,6 @@ "requires": { "cross-spawn": "^4", "signal-exit": "^3.0.0" - }, - "dependencies": { - "cross-spawn": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-4.0.2.tgz", - "integrity": "sha1-e5JHYhwjrf3ThWAEqCPL45dCTUE=", - "dev": true, - "requires": { - "lru-cache": "^4.0.1", - "which": "^1.2.9" - } - } } }, "fs-extra": { @@ -597,13 +579,6 @@ "graceful-fs": "^4.2.0", "jsonfile": "^4.0.0", "universalify": "^0.1.0" - }, - "dependencies": { - "graceful-fs": { - "version": "4.2.0", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.0.tgz", - "integrity": "sha512-jpSvDPV4Cq/bgtpndIWbI5hmYxhQGHPC4d4cqBPb4DLniCfhJokdXhwhaDuLBGLQdvvRum/UiX6ECVIPvDXqdg==" - } } }, "fs.realpath": { @@ -623,19 +598,10 @@ "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", "dev": true }, - "get-stream": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz", - "integrity": "sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==", - "dev": true, - "requires": { - "pump": "^3.0.0" - } - }, "glob": { - "version": "7.1.3", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.3.tgz", - "integrity": "sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ==", + "version": "7.1.5", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.5.tgz", + "integrity": "sha512-J9dlskqUXK1OeTOYBEn5s8aMukWMwWfs+rPTn/jn50Ux4MNXVhubL1wu/j2t+H4NVI+cXEcCaYellqaPVGXNqQ==", "requires": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -652,9 +618,9 @@ "dev": true }, "graceful-fs": { - "version": "4.1.15", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.15.tgz", - "integrity": "sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA==" + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.3.tgz", + "integrity": "sha512-a30VEBm4PEdx1dRB7MFK7BejejvCvBronbLjht+sHuGYj8PHs7M/5Z+rt5lw551vZ7yfTCj4Vuyy3mSJytDWRQ==" }, "growl": { "version": "1.10.5", @@ -663,9 +629,9 @@ "dev": true }, "handlebars": { - "version": "4.4.3", - "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.4.3.tgz", - "integrity": "sha512-B0W4A2U1ww3q7VVthTKfh+epHx+q4mCt6iK+zEAzbMBpWQAwxCeKxEGpj/1oQTpzPXDNSOG7hmG14TsISH50yw==", + "version": "4.5.1", + "resolved": "https://registry.npmjs.org/handlebars/-/handlebars-4.5.1.tgz", + "integrity": "sha512-C29UoFzHe9yM61lOsIlCE5/mQVGrnIOrOq7maQl76L7tYPCgC1og0Ajt6uWnX4ZTxBPnjw+CUvawphwCfJgUnA==", "requires": { "neo-async": "^2.6.0", "optimist": "^0.6.1", @@ -710,14 +676,14 @@ "dev": true }, "highlight.js": { - "version": "9.15.10", - "resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-9.15.10.tgz", - "integrity": "sha512-RoV7OkQm0T3os3Dd2VHLNMoaoDVx77Wygln3n9l5YV172XonWG6rgQD3XnF/BuFFZw9A0TJgmMSO8FEWQgvcXw==" + "version": "9.16.2", + "resolved": "https://registry.npmjs.org/highlight.js/-/highlight.js-9.16.2.tgz", + "integrity": "sha512-feMUrVLZvjy0oC7FVJQcSQRqbBq9kwqnYE4+Kj9ZjbHh3g+BisiPgF49NyQbVLNdrL/qqZr3Ca9yOKwgn2i/tw==" }, "hosted-git-info": { - "version": "2.7.1", - "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.7.1.tgz", - "integrity": "sha512-7T/BxH19zbcCTa8XkMlbK5lTo1WtgkFi3GvdWEyNuc4Vex7/9Dqbnpsf4JMydcfj9HCg4zUWFTL3Za6lapg5/w==", + "version": "2.8.5", + "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.5.tgz", + "integrity": "sha512-kssjab8CvdXfcXMXVcvsXum4Hwdq9XGtRD3TteMEvEbq0LXyiNQr6AprqKqfeaDXze7SxWvRxdpwE6ku7ikLkg==", "dev": true }, "imurmurhash": { @@ -736,21 +702,15 @@ } }, "inherits": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", - "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" }, "interpret": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/interpret/-/interpret-1.2.0.tgz", "integrity": "sha512-mT34yGKMNceBQUoVn7iCDKDntA7SC6gycMAWzGx1z/CMCTV7b2AAtXlo3nRyHZ1FelRkQbQjprHSYGwzLtkVbw==" }, - "invert-kv": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz", - "integrity": "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==", - "dev": true - }, "is-arrayish": { "version": "0.2.1", "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", @@ -842,9 +802,9 @@ }, "dependencies": { "semver": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-6.0.0.tgz", - "integrity": "sha512-0UewU+9rFapKFnlbirLi3byoOuhrSsli/z/ihNnvM24vgF+8sNBiI1LZPBSH9wJKUwaUbw+s3hToDLCXkrghrQ==", + "version": "6.3.0", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.0.tgz", + "integrity": "sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==", "dev": true } } @@ -940,15 +900,6 @@ "graceful-fs": "^4.1.6" } }, - "lcid": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz", - "integrity": "sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA==", - "dev": true, - "requires": { - "invert-kv": "^2.0.0" - } - }, "load-json-file": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-4.0.0.tgz", @@ -1017,14 +968,6 @@ "requires": { "pify": "^4.0.1", "semver": "^5.6.0" - }, - "dependencies": { - "semver": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.0.tgz", - "integrity": "sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA==", - "dev": true - } } }, "make-error": { @@ -1033,31 +976,11 @@ "integrity": "sha512-c3sIjNUow0+8swNwVpqoH4YCShKNFkMaw6oH1mNS2haDZQqkeZFlHS3dhoeEbKKmJB4vXpJucU6oH75aDYeE9g==", "dev": true }, - "map-age-cleaner": { - "version": "0.1.3", - "resolved": "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz", - "integrity": "sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w==", - "dev": true, - "requires": { - "p-defer": "^1.0.0" - } - }, "marked": { "version": "0.7.0", "resolved": "https://registry.npmjs.org/marked/-/marked-0.7.0.tgz", "integrity": "sha512-c+yYdCZJQrsRjTPhUx7VKkApw9bwDkNbHUKo1ovgcfDjb2kc8rLuRbIFyXL5WOEUwzSSKo3IXpph2K6DqB/KZg==" }, - "mem": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/mem/-/mem-4.3.0.tgz", - "integrity": "sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w==", - "dev": true, - "requires": { - "map-age-cleaner": "^0.1.1", - "mimic-fn": "^2.0.0", - "p-is-promise": "^2.0.0" - } - }, "merge-source-map": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/merge-source-map/-/merge-source-map-1.1.0.tgz", @@ -1067,12 +990,6 @@ "source-map": "^0.6.1" } }, - "mimic-fn": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", - "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", - "dev": true - }, "minimatch": { "version": "3.0.4", "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", @@ -1104,9 +1021,9 @@ } }, "mocha": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/mocha/-/mocha-6.2.1.tgz", - "integrity": "sha512-VCcWkLHwk79NYQc8cxhkmI8IigTIhsCwZ6RTxQsqK6go4UvEhzJkYuHm8B2YtlSxcYq2fY+ucr4JBwoD6ci80A==", + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/mocha/-/mocha-6.2.2.tgz", + "integrity": "sha512-FgDS9Re79yU1xz5d+C4rv1G7QagNGHZ+iXF81hO8zY35YZZcLEsJVfFolfsqKFWunATEvNzMK0r/CwWd/szO9A==", "dev": true, "requires": { "ansi-colors": "3.2.3", @@ -1134,23 +1051,6 @@ "yargs-unparser": "1.6.0" }, "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", - "dev": true - }, - "cliui": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", - "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", - "dev": true, - "requires": { - "string-width": "^3.1.0", - "strip-ansi": "^5.2.0", - "wrap-ansi": "^5.1.0" - } - }, "glob": { "version": "7.1.3", "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.3.tgz", @@ -1164,74 +1064,6 @@ "once": "^1.3.0", "path-is-absolute": "^1.0.0" } - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "dev": true, - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - }, - "supports-color": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.0.0.tgz", - "integrity": "sha512-on9Kwidc1IUQo+bQdhi8+Tijpo0e1SS6RoGo2guUwn5vdaxw8RXOF9Vb2ws+ihWOmh4JnCJOvaziZWP1VABaLg==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - }, - "wrap-ansi": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", - "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.0", - "string-width": "^3.0.0", - "strip-ansi": "^5.0.0" - } - }, - "yargs": { - "version": "13.3.0", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.0.tgz", - "integrity": "sha512-2eehun/8ALW8TLoIl7MVaRUrg+yCnenu8B4kBlRxj3GJGDKU1Og7sMXPNm1BYyM1DOJmTZ4YeN/Nwxv+8XJsUA==", - "dev": true, - "requires": { - "cliui": "^5.0.0", - "find-up": "^3.0.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^3.0.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^13.1.1" - } - }, - "yargs-parser": { - "version": "13.1.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.1.tgz", - "integrity": "sha512-oVAVsHz6uFrg3XQheFII8ESO2ssAf9luWuAd6Wexsu4F3OtIW0o8IribPXYrD4WC24LWtPrJlGy87y5udK+dxQ==", - "dev": true, - "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - } } } }, @@ -1258,12 +1090,6 @@ "integrity": "sha512-AO81vsIO1k1sM4Zrd6Hu7regmJN1NSiAja10gc4bX3F0wd+9rQmcuHQaHVQCYIEC8iFXnE+mavh23GOt7wBgug==", "dev": true }, - "nice-try": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", - "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", - "dev": true - }, "node-environment-flags": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/node-environment-flags/-/node-environment-flags-1.0.5.tgz", @@ -1272,14 +1098,6 @@ "requires": { "object.getownpropertydescriptors": "^2.0.3", "semver": "^5.7.0" - }, - "dependencies": { - "semver": { - "version": "5.7.1", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", - "dev": true - } } }, "normalize-package-data": { @@ -1292,34 +1110,8 @@ "resolve": "^1.10.0", "semver": "2 || 3 || 4 || 5", "validate-npm-package-license": "^3.0.1" - }, - "dependencies": { - "resolve": { - "version": "1.11.0", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.11.0.tgz", - "integrity": "sha512-WL2pBDjqT6pGUNSUzMw00o4T7If+z4H2x3Gz893WoUQ5KW8Vr9txp00ykiP16VBaZF5+j/OcXJHZ9+PCvdiDKw==", - "dev": true, - "requires": { - "path-parse": "^1.0.6" - } - } - } - }, - "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=", - "dev": true, - "requires": { - "path-key": "^2.0.0" } }, - "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=", - "dev": true - }, "nyc": { "version": "14.1.1", "resolved": "https://registry.npmjs.org/nyc/-/nyc-14.1.1.tgz", @@ -1351,22 +1143,6 @@ "uuid": "^3.3.2", "yargs": "^13.2.2", "yargs-parser": "^13.0.0" - }, - "dependencies": { - "glob": { - "version": "7.1.4", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.4.tgz", - "integrity": "sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A==", - "dev": true, - "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - } - } } }, "object-inspect": { @@ -1426,39 +1202,10 @@ "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=", "dev": true }, - "os-locale": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/os-locale/-/os-locale-3.1.0.tgz", - "integrity": "sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q==", - "dev": true, - "requires": { - "execa": "^1.0.0", - "lcid": "^2.0.0", - "mem": "^4.0.0" - } - }, - "p-defer": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/p-defer/-/p-defer-1.0.0.tgz", - "integrity": "sha1-n26xgvbJqozXQwBKfU+WsZaw+ww=", - "dev": true - }, - "p-finally": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", - "integrity": "sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4=", - "dev": true - }, - "p-is-promise": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/p-is-promise/-/p-is-promise-2.1.0.tgz", - "integrity": "sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg==", - "dev": true - }, "p-limit": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.2.0.tgz", - "integrity": "sha512-pZbTJpoUsCzV48Mc9Nh51VbwO0X9cuPFE8gYwx9BTCt9SF8/b7Zljd2fVgOxhIF/HDTKgpVzs+GPhyKfjLLFRQ==", + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.2.1.tgz", + "integrity": "sha512-85Tk+90UCVWvbDavCLKPOLC9vvY8OwEX/RtKF+/1OADJMVlFfEHOiMTPVyxg7mk/dKa+ipdHm0OUkTvCpMTuwg==", "dev": true, "requires": { "p-try": "^2.0.0" @@ -1512,12 +1259,6 @@ "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=", - "dev": true - }, "path-parse": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz", @@ -1566,16 +1307,6 @@ "integrity": "sha1-8FKijacOYYkX7wqKw0wa5aaChrM=", "dev": true }, - "pump": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", - "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", - "dev": true, - "requires": { - "end-of-stream": "^1.1.0", - "once": "^1.3.1" - } - }, "read-pkg": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-3.0.0.tgz", @@ -1627,9 +1358,9 @@ "dev": true }, "resolve": { - "version": "1.10.0", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.10.0.tgz", - "integrity": "sha512-3sUr9aq5OfSg2S9pNtPA9hL1FVEAjvfOC4leW0SNf/mpnaakz2a9femSd6LqAww2RaFctwyf1lCqnTHuF1rxDg==", + "version": "1.12.0", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.12.0.tgz", + "integrity": "sha512-B/dOmuoAik5bKcD6s6nXDCjzUKnaDvdkRyAk6rsmsKLipWj4797iothd7jmmUhWTfinVMU+wc56rYKsit2Qy4w==", "requires": { "path-parse": "^1.0.6" } @@ -1641,28 +1372,12 @@ "dev": true }, "rimraf": { - "version": "2.6.3", - "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.6.3.tgz", - "integrity": "sha512-mwqeW5XsA2qAejG46gYdENaxXjx9onRNCfn7L0duuP4hCuTIi/QO7PDK07KJfp1d+izWPrzEJDcSqBa0OZQriA==", + "version": "2.7.1", + "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", + "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", "dev": true, "requires": { "glob": "^7.1.3" - }, - "dependencies": { - "glob": { - "version": "7.1.4", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.4.tgz", - "integrity": "sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A==", - "dev": true, - "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - } - } } }, "safe-buffer": { @@ -1672,9 +1387,9 @@ "dev": true }, "semver": { - "version": "5.7.0", - "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.0.tgz", - "integrity": "sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA==", + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", + "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", "dev": true }, "set-blocking": { @@ -1683,21 +1398,6 @@ "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", "dev": true }, - "shebang-command": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", - "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=", - "dev": true, - "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=", - "dev": true - }, "shelljs": { "version": "0.8.3", "resolved": "https://registry.npmjs.org/shelljs/-/shelljs-0.8.3.tgz", @@ -1720,9 +1420,9 @@ "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==" }, "source-map-support": { - "version": "0.5.13", - "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.13.tgz", - "integrity": "sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w==", + "version": "0.5.16", + "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.16.tgz", + "integrity": "sha512-efyLRJDr68D9hBBNIPWFjhpFzURh+KJykQwvMyW5UiZzYwoF6l4YMMDIJJEyFWxWCqfyxLzz6tSfUFR+kXXsVQ==", "dev": true, "requires": { "buffer-from": "^1.0.0", @@ -1730,9 +1430,9 @@ } }, "spawn-wrap": { - "version": "1.4.2", - "resolved": "https://registry.npmjs.org/spawn-wrap/-/spawn-wrap-1.4.2.tgz", - "integrity": "sha512-vMwR3OmmDhnxCVxM8M+xO/FtIp6Ju/mNaDfCMMW7FDcLRTPFWUswec4LXJHTJE2hwTI9O0YBfygu4DalFl7Ylg==", + "version": "1.4.3", + "resolved": "https://registry.npmjs.org/spawn-wrap/-/spawn-wrap-1.4.3.tgz", + "integrity": "sha512-IgB8md0QW/+tWqcavuFgKYR/qIRvJkRLPJDFaoXtLLUaVcCDK0+HeFTkmQHj3eprcYhc+gOl0aEA1w7qZlYezw==", "dev": true, "requires": { "foreground-child": "^1.5.6", @@ -1770,9 +1470,9 @@ } }, "spdx-license-ids": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.4.tgz", - "integrity": "sha512-7j8LYJLeY/Yb6ACbQ7F76qy5jHkp0U6jgBfJsk97bwWlVUnUWsAgpyaCvo17h0/RQGnQ036tVDomiwoI4pDkQA==", + "version": "3.0.5", + "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.5.tgz", + "integrity": "sha512-J+FWzZoynJEXGphVIS+XEh3kFSjZX/1i9gFBaWQcB+/tmpe2qUsSBABpcxqxnAxFdiUFEgAX1bjYGQvIZmoz9Q==", "dev": true }, "sprintf-js": { @@ -1826,18 +1526,21 @@ "integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=", "dev": true }, - "strip-eof": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", - "integrity": "sha1-u0P/VZim6wXYm1n80SnJgzE2Br8=", - "dev": true - }, "strip-json-comments": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", "dev": true }, + "supports-color": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-6.0.0.tgz", + "integrity": "sha512-on9Kwidc1IUQo+bQdhi8+Tijpo0e1SS6RoGo2guUwn5vdaxw8RXOF9Vb2ws+ihWOmh4JnCJOvaziZWP1VABaLg==", + "dev": true, + "requires": { + "has-flag": "^3.0.0" + } + }, "test-exclude": { "version": "5.2.3", "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-5.2.3.tgz", @@ -1848,22 +1551,6 @@ "minimatch": "^3.0.4", "read-pkg-up": "^4.0.0", "require-main-filename": "^2.0.0" - }, - "dependencies": { - "glob": { - "version": "7.1.4", - "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.4.tgz", - "integrity": "sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A==", - "dev": true, - "requires": { - "fs.realpath": "^1.0.0", - "inflight": "^1.0.4", - "inherits": "2", - "minimatch": "^3.0.4", - "once": "^1.3.0", - "path-is-absolute": "^1.0.0" - } - } } }, "to-fast-properties": { @@ -1872,12 +1559,6 @@ "integrity": "sha1-3F5pjL0HkmW8c+A3doGk5Og/YW4=", "dev": true }, - "trim-right": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/trim-right/-/trim-right-1.0.1.tgz", - "integrity": "sha1-yy4SAwZ+DI3h9hQJS5/kVwTqYAM=", - "dev": true - }, "ts-node": { "version": "8.4.1", "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.4.1.tgz", @@ -5541,12 +5222,12 @@ "integrity": "sha512-unoCll1+l+YK4i4F8f22TaNVPRHcD9PA3yCuZ8g5e0qGqlVlJ/8FSateOLLSagn+Yg5+ZwuPkL8LFUc0Jcvksg==" }, "uglify-js": { - "version": "3.6.1", - "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.6.1.tgz", - "integrity": "sha512-+dSJLJpXBb6oMHP+Yvw8hUgElz4gLTh82XuX68QiJVTXaE5ibl6buzhNkQdYhBlIhozWOC9ge16wyRmjG4TwVQ==", + "version": "3.6.7", + "resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.6.7.tgz", + "integrity": "sha512-4sXQDzmdnoXiO+xvmTzQsfIiwrjUCSA95rSP4SEd8tDb51W2TiDOlL76Hl+Kw0Ie42PSItCW8/t6pBNCF2R48A==", "optional": true, "requires": { - "commander": "2.20.0", + "commander": "~2.20.3", "source-map": "~0.6.1" } }, @@ -5556,9 +5237,9 @@ "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==" }, "uuid": { - "version": "3.3.2", - "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.3.2.tgz", - "integrity": "sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA==", + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.3.3.tgz", + "integrity": "sha512-pW0No1RGHgzlpHJO1nsVrHKpOEIxkGg1xB+v0ZmdNH5OAeAwzAVrCnI2/6Mtx+Uys6iaylxa+D3g4j63IKKjSQ==", "dev": true }, "validate-npm-package-license": { @@ -5601,48 +5282,40 @@ "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=", + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", + "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", "dev": true, "requires": { - "string-width": "^1.0.1", - "strip-ansi": "^3.0.1" + "ansi-styles": "^3.2.0", + "string-width": "^3.0.0", + "strip-ansi": "^5.0.0" }, "dependencies": { "ansi-regex": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", "dev": true }, - "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=", - "dev": true, - "requires": { - "number-is-nan": "^1.0.0" - } - }, "string-width": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", - "integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", "dev": true, "requires": { - "code-point-at": "^1.0.0", - "is-fullwidth-code-point": "^1.0.0", - "strip-ansi": "^3.0.0" + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" } }, "strip-ansi": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", - "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", + "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", "dev": true, "requires": { - "ansi-regex": "^2.0.0" + "ansi-regex": "^4.1.0" } } } @@ -5653,9 +5326,9 @@ "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" }, "write-file-atomic": { - "version": "2.4.2", - "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.4.2.tgz", - "integrity": "sha512-s0b6vB3xIVRLWywa6X9TOMA7k9zio0TMOsl9ZnDkliA/cfJlpHXAscj0gbHVJiTdIuAYpIyqS5GW91fqm6gG5g==", + "version": "2.4.3", + "resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-2.4.3.tgz", + "integrity": "sha512-GaETH5wwsX+GcnzhPgKcKjJ6M2Cq3/iZp1WyY/X1CSqrW+jVNM9Y7D8EC2sM4ZG/V8wZlSniJnCKWPmBYAucRQ==", "dev": true, "requires": { "graceful-fs": "^4.1.11", @@ -5676,22 +5349,21 @@ "dev": true }, "yargs": { - "version": "13.2.2", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.2.2.tgz", - "integrity": "sha512-WyEoxgyTD3w5XRpAQNYUB9ycVH/PQrToaTXdYXRdOXvEy1l19br+VJsc0vcO8PTGg5ro/l/GY7F/JMEBmI0BxA==", + "version": "13.3.0", + "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.0.tgz", + "integrity": "sha512-2eehun/8ALW8TLoIl7MVaRUrg+yCnenu8B4kBlRxj3GJGDKU1Og7sMXPNm1BYyM1DOJmTZ4YeN/Nwxv+8XJsUA==", "dev": true, "requires": { - "cliui": "^4.0.0", + "cliui": "^5.0.0", "find-up": "^3.0.0", "get-caller-file": "^2.0.1", - "os-locale": "^3.1.0", "require-directory": "^2.1.1", "require-main-filename": "^2.0.0", "set-blocking": "^2.0.0", "string-width": "^3.0.0", "which-module": "^2.0.0", "y18n": "^4.0.0", - "yargs-parser": "^13.0.0" + "yargs-parser": "^13.1.1" }, "dependencies": { "ansi-regex": { @@ -5723,9 +5395,9 @@ } }, "yargs-parser": { - "version": "13.0.0", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.0.0.tgz", - "integrity": "sha512-w2LXjoL8oRdRQN+hOyppuXs+V/fVAYtpcrRxZuF7Kt/Oc+Jr2uAcVntaUTNT6w5ihoWfFDpNY8CPx1QskxZ/pw==", + "version": "13.1.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.1.tgz", + "integrity": "sha512-oVAVsHz6uFrg3XQheFII8ESO2ssAf9luWuAd6Wexsu4F3OtIW0o8IribPXYrD4WC24LWtPrJlGy87y5udK+dxQ==", "dev": true, "requires": { "camelcase": "^5.0.0", @@ -5741,84 +5413,6 @@ "flat": "^4.1.0", "lodash": "^4.17.15", "yargs": "^13.3.0" - }, - "dependencies": { - "ansi-regex": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", - "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", - "dev": true - }, - "cliui": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz", - "integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==", - "dev": true, - "requires": { - "string-width": "^3.1.0", - "strip-ansi": "^5.2.0", - "wrap-ansi": "^5.1.0" - } - }, - "string-width": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", - "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", - "dev": true, - "requires": { - "emoji-regex": "^7.0.1", - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^5.1.0" - } - }, - "strip-ansi": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz", - "integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==", - "dev": true, - "requires": { - "ansi-regex": "^4.1.0" - } - }, - "wrap-ansi": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz", - "integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==", - "dev": true, - "requires": { - "ansi-styles": "^3.2.0", - "string-width": "^3.0.0", - "strip-ansi": "^5.0.0" - } - }, - "yargs": { - "version": "13.3.0", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.0.tgz", - "integrity": "sha512-2eehun/8ALW8TLoIl7MVaRUrg+yCnenu8B4kBlRxj3GJGDKU1Og7sMXPNm1BYyM1DOJmTZ4YeN/Nwxv+8XJsUA==", - "dev": true, - "requires": { - "cliui": "^5.0.0", - "find-up": "^3.0.0", - "get-caller-file": "^2.0.1", - "require-directory": "^2.1.1", - "require-main-filename": "^2.0.0", - "set-blocking": "^2.0.0", - "string-width": "^3.0.0", - "which-module": "^2.0.0", - "y18n": "^4.0.0", - "yargs-parser": "^13.1.1" - } - }, - "yargs-parser": { - "version": "13.1.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.1.tgz", - "integrity": "sha512-oVAVsHz6uFrg3XQheFII8ESO2ssAf9luWuAd6Wexsu4F3OtIW0o8IribPXYrD4WC24LWtPrJlGy87y5udK+dxQ==", - "dev": true, - "requires": { - "camelcase": "^5.0.0", - "decamelize": "^1.2.0" - } - } } }, "yn": { diff --git a/package.json b/package.json index d2c0f705a..690c6d80e 100644 --- a/package.json +++ b/package.json @@ -65,7 +65,7 @@ ], "scripts": { "pretest": "node scripts/copy_test_files.js", - "test": "nyc --reporter=html --reporter=text-summary mocha --timeout=10000 dist/test/*.test.js", + "test": "nyc --reporter=html --reporter=text-summary mocha --prof --timeout=10000 dist/test/*.test.js", "test:ts": "mocha --require ts-node/register --watch-extensions ts --timeout=10000 src/test/*.test.ts", "build": "tsc --project .", "postbuild": "node scripts/replace_application_version.js", @@ -73,7 +73,7 @@ "lint": "tslint --project .", "prepublishOnly": "npm run lint && npm run build_and_test", "prepare": "npm run build", - "clean": "rm -rf node_modules package-lock.json lib coverage" + "clean": "rimraf node_modules package-lock.json lib coverage" }, "keywords": [ "typescript", diff --git a/scripts/rebuild_specs.js b/scripts/rebuild_specs.js index b79b9f642..010509fb8 100644 --- a/scripts/rebuild_specs.js +++ b/scripts/rebuild_specs.js @@ -31,80 +31,97 @@ const conversions = [ () => app.options.setValue('categorizeByGroup', false), () => app.options.setValue('categorizeByGroup', true) ], -] +]; -fs.remove(path.join(__dirname, '../src/test/renderer/specs')) - .then(() => fs.readdir(base)) - .then(dirs => { - // Get converter directories - return Promise.all(dirs.map(dir => { - const dirPath = path.join(base, dir); - return Promise.all([dirPath, fs.stat(dirPath)]); +/** + * Rebuilds the converter specs for the provided dirs. + * @param {string[]} dirs + */ +function rebuildConverterTests(dirs) { + return Promise.all(dirs.map(fullPath => { + console.log(fullPath); + const src = app.expandInputFiles([fullPath]); + return Promise.all(conversions.map(([file, before, after]) => { + const out = path.join(fullPath, `${file}.json`); + if (fs.existsSync(out)) { + TypeDoc.resetReflectionID(); + before(); + const result = app.convert(src); + const data = JSON.stringify(result.toObject(), null, ' ') + .split(TypeDoc.normalizePath(base)) + .join('%BASE%'); + after(); + return fs.writeFile(out, data); + } })); - }).then(dirs => { - // Rebuild converter specs - return dirs.map(([fullPath, stat]) => { - if (!stat.isDirectory()) return; + })); +} - console.log(fullPath); - const src = app.expandInputFiles([fullPath]); - return Promise.all(conversions.map(([file, before, after]) => { - const out = path.join(fullPath, `${file}.json`); - if (fs.existsSync(out)) { - TypeDoc.resetReflectionID(); - before(); - const result = app.convert(src); - const data = JSON.stringify(result.toObject(), null, ' ') - .split(TypeDoc.normalizePath(base)) - .join('%BASE%'); - after(); - return fs.writeFile(out, data); - } - })); - }) - }).then(() => { - // Rebuild renderer example - const src = path.join(__dirname, '../examples/basic/src'); - const out = path.join(__dirname, '../src/test/renderer/specs'); +async function rebuildRendererTest() { + await fs.remove(path.join(__dirname, '../src/test/renderer/specs')); + const src = path.join(__dirname, '../examples/basic/src'); + const out = path.join(__dirname, '../src/test/renderer/specs'); - return fs.remove(out) - .then(() => app.generateDocs(app.expandInputFiles([src]), out)) - .then(() => fs.remove(path.join(out, 'assets'))) - .then(() => out); - }).then(out => { - // Rewrite GitHub urls + await fs.remove(out) + app.generateDocs(app.expandInputFiles([src]), out) + await fs.remove(path.join(out, 'assets')) - /** - * Avoiding sync methods here is... difficult. - * @param {string} base - * @param {string} dir - * @param {string[]} results - * @returns {string[]} - */ - function getFiles(base, dir = '', results = []) { - const files = fs.readdirSync(path.join(base, dir)); - for (const file of files) { - const relativeToBase = path.join(dir, file); - if (fs.statSync(path.join(base, relativeToBase)).isDirectory()) { - getFiles(base, relativeToBase, results); - } else { - results.push(relativeToBase); - } + /** + * Avoiding sync methods here is... difficult. + * @param {string} base + * @param {string} dir + * @param {string[]} results + * @returns {string[]} + */ + function getFiles(base, dir = '', results = []) { + const files = fs.readdirSync(path.join(base, dir)); + for (const file of files) { + const relativeToBase = path.join(dir, file); + if (fs.statSync(path.join(base, relativeToBase)).isDirectory()) { + getFiles(base, relativeToBase, results); + } else { + results.push(relativeToBase); } - return results; } + return results; + } - const gitHubRegExp = /https:\/\/github.com\/[A-Za-z0-9\-]+\/typedoc\/blob\/[^\/]*\/examples/g; - return getFiles(out).map(file => { - const full = path.join(out, file); - return fs.readFile(full, { encoding: 'utf-8' }) - .then(text => fs.writeFile( - full, - text.replace(gitHubRegExp, 'https://github.com/sebastian-lenz/typedoc/blob/master/examples') - )); - }); - }) - .catch(reason => { - console.error(reason); - process.exit(1); + const gitHubRegExp = /https:\/\/github.com\/[A-Za-z0-9\-]+\/typedoc\/blob\/[^\/]*\/examples/g; + return getFiles(out).map(file => { + const full = path.join(out, file); + return fs.readFile(full, { encoding: 'utf-8' }) + .then(text => fs.writeFile( + full, + text.replace(gitHubRegExp, 'https://github.com/sebastian-lenz/typedoc/blob/master/examples') + )); }); +} + +async function main(command = 'all', filter = '') { + if (!['all', 'converter', 'renderer'].includes(command)) { + console.error('Invalid command. Usage: node scripts/rebuild_specs.js [filter]'); + throw new Error(); + } + + if (['all', 'converter'].includes(command)) { + const dirs = await Promise.all((await fs.readdir(base)).map(dir => { + const dirPath = path.join(base, dir); + return Promise.all([dirPath, fs.stat(dirPath)]); + })); + + await rebuildConverterTests(dirs.filter(([fullPath, stat]) => { + if (!stat.isDirectory()) return false; + return fullPath.endsWith(filter); + }).map(([path]) => path)); + } + + if (['all', 'renderer'].includes(command)) { + await fs.remove(path.join(__dirname, '../src/test/renderer/specs')); + await rebuildRendererTest(); + } +} + +main(process.argv[2], process.argv[3]).catch(reason => { + console.error(reason); + process.exit(1); +}); diff --git a/src/lib/application.ts b/src/lib/application.ts index 2359ee43c..d31e4c035 100644 --- a/src/lib/application.ts +++ b/src/lib/application.ts @@ -162,12 +162,6 @@ export class Application extends ChildableComponent { if (ts.isArrayBindingPattern(node.name) || ts.isObjectBindingPattern(node.name)) { diff --git a/src/lib/converter/factories/signature.ts b/src/lib/converter/factories/signature.ts index d7059ce5a..0d11cc3e8 100644 --- a/src/lib/converter/factories/signature.ts +++ b/src/lib/converter/factories/signature.ts @@ -1,6 +1,6 @@ import * as ts from 'typescript'; -import { ReflectionKind, SignatureReflection, ContainerReflection, DeclarationReflection, Type } from '../../models/index'; +import { ReflectionKind, SignatureReflection, ContainerReflection, DeclarationReflection, Type, ReflectionFlag } from '../../models/index'; import { Context } from '../context'; import { Converter } from '../converter'; import { createParameter } from './parameter'; @@ -22,6 +22,7 @@ export function createSignature(context: Context, node: ts.SignatureDeclaration, } const signature = new SignatureReflection(name, kind, container); + signature.flags.setFlag(ReflectionFlag.Exported, context.scope.flags.isExported); context.registerReflection(signature, node); context.withScope(signature, node.typeParameters, true, () => { node.parameters.forEach((parameter: ts.ParameterDeclaration) => { diff --git a/src/lib/converter/factories/type-parameter.ts b/src/lib/converter/factories/type-parameter.ts index 468089059..33930a252 100644 --- a/src/lib/converter/factories/type-parameter.ts +++ b/src/lib/converter/factories/type-parameter.ts @@ -1,6 +1,6 @@ import * as ts from 'typescript'; -import { TypeParameterContainer, TypeParameterReflection, TypeParameterType } from '../../models/index'; +import { TypeParameterContainer, TypeParameterReflection, TypeParameterType, ReflectionFlag } from '../../models/index'; import { Context } from '../context'; import { Converter } from '../converter'; @@ -23,6 +23,7 @@ export function createTypeParameter(context: Context, node: ts.TypeParameterDecl const reflection = context.scope; const typeParameterReflection = new TypeParameterReflection(typeParameter, reflection); + typeParameterReflection.flags.setFlag(ReflectionFlag.Exported, reflection.flags.isExported); if (!reflection.typeParameters) { reflection.typeParameters = []; diff --git a/src/lib/converter/nodes/literal-type.ts b/src/lib/converter/nodes/literal-type.ts index fc4c91a1e..30fb0f21a 100644 --- a/src/lib/converter/nodes/literal-type.ts +++ b/src/lib/converter/nodes/literal-type.ts @@ -1,6 +1,6 @@ import * as ts from 'typescript'; -import { Reflection } from '../../models/index'; +import { Reflection, ReflectionFlag } from '../../models/index'; import { Context } from '../context'; import { Component, ConverterNodeComponent } from '../components'; @@ -23,7 +23,10 @@ export class TypeLiteralConverter extends ConverterNodeComponent { - this.owner.convertNode(context, node); + const reflection = this.owner.convertNode(context, node); + if (reflection) { + reflection.flags.setFlag(ReflectionFlag.Exported, context.scope.flags.isExported); + } }); } diff --git a/src/lib/converter/types/reference.ts b/src/lib/converter/types/reference.ts index 9bae1760b..d4f53072b 100644 --- a/src/lib/converter/types/reference.ts +++ b/src/lib/converter/types/reference.ts @@ -1,7 +1,7 @@ import * as ts from 'typescript'; import { Type, IntrinsicType, ReflectionType } from '../../models/types/index'; -import { ReflectionKind, DeclarationReflection } from '../../models/reflections/index'; +import { ReflectionKind, DeclarationReflection, ReflectionFlag } from '../../models/reflections/index'; import { createReferenceType } from '../factories/index'; import { Component, ConverterTypeComponent, TypeNodeConverter } from '../components'; import { Context } from '../context'; @@ -115,16 +115,15 @@ export class ReferenceConverter extends ConverterTypeComponent implements TypeNo if (context.visitStack.includes(declaration)) { if (declaration.kind === ts.SyntaxKind.TypeLiteral || declaration.kind === ts.SyntaxKind.ObjectLiteralExpression) { - // TODO: Check if this type assertion is safe and document. - return createReferenceType(context, declaration.parent.symbol!); + return createReferenceType(context, declaration.parent.symbol); } else { - // TODO: Check if this type assertion is safe and document. - return createReferenceType(context, declaration.symbol!); + return createReferenceType(context, declaration.symbol); } } } const declaration = new DeclarationReflection('__type', ReflectionKind.TypeLiteral, context.scope); + declaration.flags.setFlag(ReflectionFlag.Exported, context.scope.flags.isExported); context.registerReflection(declaration, undefined, symbol); context.trigger(Converter.EVENT_CREATE_DECLARATION, declaration, node); diff --git a/src/test/converter.test.ts b/src/test/converter.test.ts index 112e45278..3da51ecc3 100644 --- a/src/test/converter.test.ts +++ b/src/test/converter.test.ts @@ -3,62 +3,13 @@ import * as FS from 'fs'; import * as Path from 'path'; import Assert = require('assert'); -function compareReflections(fixture, spec, path?: string) { - path = (path ? path + '/' : '') + spec.name; - Assert.deepEqual(fixture, spec); +const base = Path.join(__dirname, 'converter'); - for (let key in spec) { - if (!spec.hasOwnProperty(key)) { - continue; - } - Assert(fixture.hasOwnProperty(key), path + ': Missing property "' + key + '"'); - } - - for (let key in fixture) { - if (!fixture.hasOwnProperty(key) || typeof fixture[key] === 'undefined') { - continue; - } - Assert(spec.hasOwnProperty(key), path + ': Unknown property "' + key + '"'); - - const a = fixture[key]; - const b = spec[key]; - Assert(a instanceof Object === b instanceof Object, path + ': Property "' + key + '" type mismatch'); - - if (a instanceof Object) { - switch (key) { - case 'signatures': - case 'typeParameters': - case 'children': - compareChildren(a, b, path); - break; - case 'indexSignature': - case 'getSignature': - case 'setSignature': - compareReflections(a, b, path); - break; - default: - Assert.deepEqual(a, b, path + ': Property "' + key + '" value mismatch'); - } - } else { - Assert(a === b, path + ': Property "' + key + '" value mismatch'); - } - } -} - -function compareChildren(fixture, spec, path) { - const a = fixture.map(function(child) { return child.id; }); - const b = spec.map(function(child) { return child.id; }); - - Assert(a.length === b.length, path + ': Number of children differs'); - Assert(a.every(function(u, i) { return u === b[i]; }), path + ': Children are different'); - - fixture.forEach(function(a, index) { - compareReflections(a, spec[index], path); - }); +function normalizeSerialized(data: any) { + return JSON.parse(JSON.stringify(data).split(normalizePath(base)).join('%BASE%')); } describe('Converter', function() { - const base = Path.join(__dirname, 'converter'); let app: Application; before('constructs', function() { @@ -72,6 +23,18 @@ describe('Converter', function() { }); }); + const checks: [string, () => void, () => void][] = [ + ['specs', () => { }, () => { }], + ['specs-without-exported', + () => app.options.setValue('excludeNotExported', true), + () => app.options.setValue('excludeNotExported', false) + ], + ['specs-with-lump-categories', + () => app.options.setValue('categorizeByGroup', false), + () => app.options.setValue('categorizeByGroup', true) + ] + ]; + FS.readdirSync(base).forEach(function (directory) { const path = Path.join(base, directory); if (!FS.lstatSync(path).isDirectory()) { @@ -79,29 +42,31 @@ describe('Converter', function() { } describe(directory, function() { - let result: ProjectReflection | undefined; - - it('converts fixtures', function() { - resetReflectionID(); - result = app.convert(app.expandInputFiles([path])); - Assert(result instanceof ProjectReflection, 'No reflection returned'); - }); - - it('matches specs', function() { - const specs = JSON.parse(FS.readFileSync(Path.join(path, 'specs.json')).toString()); - let data = JSON.stringify(result!.toObject(), null, ' '); - data = data.split(normalizePath(base)).join('%BASE%'); - - compareReflections(JSON.parse(data), specs); - }); + for (const [file, before, after] of checks) { + if (!FS.existsSync(Path.join(path, `${file}.json`))) { + continue; + } + + let result: ProjectReflection | undefined; + it(`[${file}] converts fixtures`, function() { + resetReflectionID(); + before(); + result = app.convert(app.expandInputFiles([path])); + after(); + Assert(result instanceof ProjectReflection, 'No reflection returned'); + }); + + it (`[${file}] matches specs`, function() { + const specs = JSON.parse(FS.readFileSync(Path.join(path, `${file}.json`), 'utf-8')); + Assert.deepStrictEqual(normalizeSerialized(result!.toObject()), specs); + }); + } }); }); }); describe('Converter with categorizeByGroup=false', function() { const base = Path.join(__dirname, 'converter'); - const categoryDir = Path.join(base, 'category'); - const classDir = Path.join(base, 'class'); let app: Application; before('constructs', function() { @@ -116,79 +81,12 @@ describe('Converter with categorizeByGroup=false', function() { }); }); - let result: ProjectReflection | undefined; - - describe('category', () => { - it('converts fixtures', function() { - resetReflectionID(); - result = app.convert(app.expandInputFiles([categoryDir])); - Assert(result instanceof ProjectReflection, 'No reflection returned'); - }); - - it('matches specs', function() { - const specs = JSON.parse(FS.readFileSync(Path.join(categoryDir, 'specs-with-lump-categories.json')).toString()); - let data = JSON.stringify(result!.toObject(), null, ' '); - data = data.split(normalizePath(base)).join('%BASE%'); - - compareReflections(JSON.parse(data), specs); - }); - }); - // verify that no categories are used when not specified during lump categorization + // this is in a separate `describe` block since it uses specs.json even though it is a categorize test. describe('class', () => { - it('converts fixtures', function() { - resetReflectionID(); - result = app.convert(app.expandInputFiles([classDir])); - Assert(result instanceof ProjectReflection, 'No reflection returned'); - }); - - it('matches specs', function() { - const specs = JSON.parse(FS.readFileSync(Path.join(classDir, 'specs.json')).toString()); - let data = JSON.stringify(result!.toObject(), null, ' '); - data = data.split(normalizePath(base)).join('%BASE%'); - - compareReflections(JSON.parse(data), specs); - }); - }); -}); - -describe('Converter with excludeNotExported=true', function() { - const base = Path.join(__dirname, 'converter'); - const exportWithLocalDir = Path.join(base, 'export-with-local'); - const classDir = Path.join(base, 'class'); - let app: Application; + let result: ProjectReflection | undefined; + const classDir = Path.join(base, 'class'); - before('constructs', function() { - app = new Application({ - mode: 'Modules', - logger: 'none', - target: 'ES5', - module: 'CommonJS', - experimentalDecorators: true, - excludeNotExported: true, - jsx: 'react' - }); - }); - - let result: ProjectReflection | undefined; - - describe('export-with-local', () => { - it('converts fixtures', function() { - resetReflectionID(); - result = app.convert(app.expandInputFiles([exportWithLocalDir])); - Assert(result instanceof ProjectReflection, 'No reflection returned'); - }); - - it('matches specs', function() { - const specs = JSON.parse(FS.readFileSync(Path.join(exportWithLocalDir, 'specs-without-exported.json')).toString()); - let data = JSON.stringify(result!.toObject(), null, ' '); - data = data.split(normalizePath(base)).join('%BASE%'); - - compareReflections(JSON.parse(data), specs); - }); - }); - - describe('class', () => { it('converts fixtures', function() { resetReflectionID(); result = app.convert(app.expandInputFiles([classDir])); @@ -196,12 +94,8 @@ describe('Converter with excludeNotExported=true', function() { }); it('matches specs', function() { - const specs = JSON.parse(FS.readFileSync(Path.join(classDir, 'specs-without-exported.json')).toString()); - let data = JSON.stringify(result!.toObject(), null, ' '); - data = data.split(normalizePath(base)).join('%BASE%'); - - compareReflections(JSON.parse(data), specs); + const specs = JSON.parse(FS.readFileSync(Path.join(classDir, 'specs.json')).toString()); + Assert.deepStrictEqual(normalizeSerialized(result!.toObject()), specs); }); }); - }); diff --git a/src/test/converter/access/specs.json b/src/test/converter/access/specs.json index 4ea320f20..d7d331751 100644 --- a/src/test/converter/access/specs.json +++ b/src/test/converter/access/specs.json @@ -92,7 +92,8 @@ "kind": 4096, "kindString": "Call signature", "flags": { - "isPrivate": true + "isPrivate": true, + "isExported": true }, "comment": { "shortText": "A function that is made private via comment." @@ -127,7 +128,8 @@ "kind": 4096, "kindString": "Call signature", "flags": { - "isProtected": true + "isProtected": true, + "isExported": true }, "comment": { "shortText": "A function that is made protected via comment." @@ -244,7 +246,8 @@ "kind": 4096, "kindString": "Call signature", "flags": { - "isPrivate": true + "isPrivate": true, + "isExported": true }, "comment": { "shortText": "A function that is made private via comment." @@ -280,7 +283,8 @@ "kind": 4096, "kindString": "Call signature", "flags": { - "isProtected": true + "isProtected": true, + "isExported": true }, "comment": { "shortText": "A function that is made protected via comment." diff --git a/src/test/converter/array/specs.json b/src/test/converter/array/specs.json index 473bfee87..a5efe145a 100644 --- a/src/test/converter/array/specs.json +++ b/src/test/converter/array/specs.json @@ -32,7 +32,9 @@ "name": "T", "kind": 131072, "kindString": "Type parameter", - "flags": {} + "flags": { + "isExported": true + } } ], "sources": [ diff --git a/src/test/converter/category/specs-with-lump-categories.json b/src/test/converter/category/specs-with-lump-categories.json index 305705e84..dae193231 100644 --- a/src/test/converter/category/specs-with-lump-categories.json +++ b/src/test/converter/category/specs-with-lump-categories.json @@ -146,7 +146,9 @@ "name": "myAbstractMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "void" @@ -243,7 +245,9 @@ "name": "myAbstractMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "void" @@ -337,7 +341,9 @@ "name": "new TestClass", "kind": 16384, "kindString": "Constructor signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Constructor short text." }, @@ -447,7 +453,9 @@ "name": "privateMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "privateMethod short text." }, @@ -480,7 +488,9 @@ "name": "protectedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "protectedMethod short text." }, @@ -513,7 +523,9 @@ "name": "publicMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "publicMethod short text." }, @@ -546,7 +558,9 @@ "name": "staticMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "staticMethod short text." }, @@ -655,7 +669,9 @@ "name": "new TestSubClass", "kind": 16384, "kindString": "Constructor signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Constructor short text." }, @@ -665,7 +681,9 @@ "name": "p1", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Constructor param" }, @@ -679,7 +697,9 @@ "name": "p2", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Private string property" }, @@ -693,7 +713,9 @@ "name": "p3", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Public number property" }, @@ -707,7 +729,9 @@ "name": "p4", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Public implicit any property\n" }, @@ -890,7 +914,9 @@ "name": "mergedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "mergedMethod short text." }, @@ -923,7 +949,9 @@ "name": "protectedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "protectedMethod short text." }, @@ -966,7 +994,9 @@ "name": "publicMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "publicMethod short text." }, @@ -1010,7 +1040,9 @@ "name": "staticMergedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "staticMergedMethod short text." }, @@ -1043,7 +1075,9 @@ "name": "staticMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "staticMethod short text." }, diff --git a/src/test/converter/category/specs.json b/src/test/converter/category/specs.json index a6a814f72..117ad530b 100644 --- a/src/test/converter/category/specs.json +++ b/src/test/converter/category/specs.json @@ -146,7 +146,9 @@ "name": "myAbstractMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "void" @@ -243,7 +245,9 @@ "name": "myAbstractMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "void" @@ -337,7 +341,9 @@ "name": "new TestClass", "kind": 16384, "kindString": "Constructor signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Constructor short text." }, @@ -447,7 +453,9 @@ "name": "privateMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "privateMethod short text." }, @@ -480,7 +488,9 @@ "name": "protectedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "protectedMethod short text." }, @@ -513,7 +523,9 @@ "name": "publicMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "publicMethod short text." }, @@ -546,7 +558,9 @@ "name": "staticMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "staticMethod short text." }, @@ -666,7 +680,9 @@ "name": "new TestSubClass", "kind": 16384, "kindString": "Constructor signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Constructor short text." }, @@ -676,7 +692,9 @@ "name": "p1", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Constructor param" }, @@ -690,7 +708,9 @@ "name": "p2", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Private string property" }, @@ -704,7 +724,9 @@ "name": "p3", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Public number property" }, @@ -718,7 +740,9 @@ "name": "p4", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Public implicit any property\n" }, @@ -901,7 +925,9 @@ "name": "mergedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "mergedMethod short text." }, @@ -934,7 +960,9 @@ "name": "protectedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "protectedMethod short text." }, @@ -977,7 +1005,9 @@ "name": "publicMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "publicMethod short text." }, @@ -1021,7 +1051,9 @@ "name": "staticMergedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "staticMergedMethod short text." }, @@ -1054,7 +1086,9 @@ "name": "staticMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "staticMethod short text." }, diff --git a/src/test/converter/class/specs-without-exported.json b/src/test/converter/class/specs-without-exported.json index 982b980b6..50aea7d6f 100644 --- a/src/test/converter/class/specs-without-exported.json +++ b/src/test/converter/class/specs-without-exported.json @@ -62,7 +62,9 @@ "name": "myAbstractMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "void" @@ -159,7 +161,9 @@ "name": "myAbstractMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "void" @@ -253,7 +257,9 @@ "name": "new TestClass", "kind": 16384, "kindString": "Constructor signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Constructor short text." }, @@ -363,7 +369,9 @@ "name": "privateMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "privateMethod short text." }, @@ -396,7 +404,9 @@ "name": "protectedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "protectedMethod short text." }, @@ -429,7 +439,9 @@ "name": "publicMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "publicMethod short text." }, @@ -462,7 +474,9 @@ "name": "staticMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "staticMethod short text." }, @@ -551,7 +565,9 @@ "name": "new TestSubClass", "kind": 16384, "kindString": "Constructor signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Constructor short text." }, @@ -561,7 +577,9 @@ "name": "p1", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Constructor param" }, @@ -575,7 +593,9 @@ "name": "p2", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Private string property" }, @@ -589,7 +609,9 @@ "name": "p3", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Public number property" }, @@ -603,7 +625,9 @@ "name": "p4", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Public implicit any property\n" }, @@ -786,7 +810,9 @@ "name": "mergedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "mergedMethod short text." }, @@ -819,7 +845,9 @@ "name": "protectedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "protectedMethod short text." }, @@ -862,7 +890,9 @@ "name": "publicMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "publicMethod short text." }, @@ -906,7 +936,9 @@ "name": "staticMergedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "staticMergedMethod short text." }, @@ -939,7 +971,9 @@ "name": "staticMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "staticMethod short text." }, diff --git a/src/test/converter/class/specs.json b/src/test/converter/class/specs.json index 94cb7bc33..968730be6 100644 --- a/src/test/converter/class/specs.json +++ b/src/test/converter/class/specs.json @@ -146,7 +146,9 @@ "name": "myAbstractMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "void" @@ -243,7 +245,9 @@ "name": "myAbstractMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "void" @@ -337,7 +341,9 @@ "name": "new TestClass", "kind": 16384, "kindString": "Constructor signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Constructor short text." }, @@ -447,7 +453,9 @@ "name": "privateMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "privateMethod short text." }, @@ -480,7 +488,9 @@ "name": "protectedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "protectedMethod short text." }, @@ -513,7 +523,9 @@ "name": "publicMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "publicMethod short text." }, @@ -546,7 +558,9 @@ "name": "staticMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "staticMethod short text." }, @@ -635,7 +649,9 @@ "name": "new TestSubClass", "kind": 16384, "kindString": "Constructor signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Constructor short text." }, @@ -645,7 +661,9 @@ "name": "p1", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Constructor param" }, @@ -659,7 +677,9 @@ "name": "p2", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Private string property" }, @@ -673,7 +693,9 @@ "name": "p3", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Public number property" }, @@ -687,7 +709,9 @@ "name": "p4", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Public implicit any property\n" }, @@ -870,7 +894,9 @@ "name": "mergedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "mergedMethod short text." }, @@ -903,7 +929,9 @@ "name": "protectedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "protectedMethod short text." }, @@ -946,7 +974,9 @@ "name": "publicMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "publicMethod short text." }, @@ -990,7 +1020,9 @@ "name": "staticMergedMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "staticMergedMethod short text." }, @@ -1023,7 +1055,9 @@ "name": "staticMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "staticMethod short text." }, diff --git a/src/test/converter/dots.in.path/specs.json b/src/test/converter/dots.in.path/specs.json index bbcdd8724..fccada61d 100644 --- a/src/test/converter/dots.in.path/specs.json +++ b/src/test/converter/dots.in.path/specs.json @@ -29,7 +29,9 @@ "name": "exportedFunction", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "This is a simple exported function." }, @@ -39,7 +41,9 @@ "name": "arg", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "EmptyInterface", diff --git a/src/test/converter/enum/specs.json b/src/test/converter/enum/specs.json index 5befe7eb5..21fcaf9e5 100644 --- a/src/test/converter/enum/specs.json +++ b/src/test/converter/enum/specs.json @@ -125,7 +125,9 @@ "name": "enumFunction", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "This is a function appended to an enumeration." }, diff --git a/src/test/converter/export-declaration/specs.json b/src/test/converter/export-declaration/specs.json index 05fcc5f37..2f2d29a7f 100644 --- a/src/test/converter/export-declaration/specs.json +++ b/src/test/converter/export-declaration/specs.json @@ -204,7 +204,9 @@ "name": "defaultSymbol", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "void" @@ -670,14 +672,18 @@ "name": "funcFromMod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 8, "name": "a", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" @@ -882,14 +888,18 @@ "name": "funcFromMod2", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 17, "name": "a", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" diff --git a/src/test/converter/export-with-local/specs-without-exported.json b/src/test/converter/export-with-local/specs-without-exported.json index e913f9e76..ff1470c3e 100644 --- a/src/test/converter/export-with-local/specs-without-exported.json +++ b/src/test/converter/export-with-local/specs-without-exported.json @@ -52,14 +52,18 @@ "name": "add", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 5, "name": "x", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" @@ -70,7 +74,9 @@ "name": "y", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" diff --git a/src/test/converter/export-with-local/specs.json b/src/test/converter/export-with-local/specs.json index 261130e50..f7acf5447 100644 --- a/src/test/converter/export-with-local/specs.json +++ b/src/test/converter/export-with-local/specs.json @@ -73,14 +73,18 @@ "name": "add", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 5, "name": "x", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" @@ -91,7 +95,9 @@ "name": "y", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" diff --git a/src/test/converter/export/specs.json b/src/test/converter/export/specs.json index 5daf6f6f8..db5b40ceb 100644 --- a/src/test/converter/export/specs.json +++ b/src/test/converter/export/specs.json @@ -52,14 +52,18 @@ "name": "add", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 5, "name": "x", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" @@ -70,7 +74,9 @@ "name": "y", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" diff --git a/src/test/converter/function/specs.json b/src/test/converter/function/specs.json index 7eea20315..5c411e653 100644 --- a/src/test/converter/function/specs.json +++ b/src/test/converter/function/specs.json @@ -32,7 +32,9 @@ "name": "moduleFunction", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "This is a function that is extended by a module." }, @@ -42,7 +44,9 @@ "name": "arg", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "An argument.\n" }, @@ -188,7 +192,9 @@ "name": "exportedFunction", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "This is a simple exported function." }, @@ -221,7 +227,9 @@ "name": "functionWithDefaults", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "This is a function with a parameter that has a default value.", "returns": "This is the return value of the function.\n" @@ -232,7 +240,9 @@ "name": "valueA", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "A parameter with a default string value." }, @@ -247,7 +257,9 @@ "name": "valueB", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "A parameter with a default numeric value." }, @@ -262,7 +274,9 @@ "name": "valueC", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "A parameter with a default NaN value." }, @@ -277,7 +291,9 @@ "name": "valueD", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "A parameter with a default boolean value." }, @@ -292,7 +308,9 @@ "name": "valueE", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "A parameter with a default null value." }, @@ -332,7 +350,9 @@ "name": "functionWithOptionalValue", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "This is a function with a parameter that is optional." }, @@ -342,7 +362,9 @@ "name": "requiredParam", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "A normal parameter." }, @@ -357,6 +379,7 @@ "kind": 32768, "kindString": "Parameter", "flags": { + "isExported": true, "isOptional": true }, "comment": { @@ -397,7 +420,9 @@ "name": "functionWithParameters", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "This is a function with multiple arguments and a return value.", "returns": "This is the return value of the function.\n" @@ -408,7 +433,9 @@ "name": "paramZ", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "This is a string parameter." }, @@ -422,7 +449,9 @@ "name": "paramG", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "This is a parameter flagged with any.\n This sentence is placed in the next line.\n" }, @@ -436,7 +465,9 @@ "name": "paramA", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "\n This is a **parameter** pointing to an interface.\n\n ~~~\n const value:BaseClass = new BaseClass('test');\n functionWithArguments('arg', 0, value);\n ~~~\n" }, @@ -561,7 +592,9 @@ "name": "multipleSignatures", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "This is the first signature of a function with multiple signatures.", "returns": "This is the return value of the function.\n" @@ -572,7 +605,9 @@ "name": "value", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "The name value.\n" }, @@ -592,7 +627,9 @@ "name": "multipleSignatures", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "This is the second signature of a function with multiple signatures.", "returns": "This is the return value of the function.\n" @@ -603,7 +640,9 @@ "name": "value", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "An object containing the name value." }, @@ -614,14 +653,18 @@ "name": "__type", "kind": 65536, "kindString": "Type literal", - "flags": {}, + "flags": { + "isExported": true + }, "children": [ { "id": 34, "name": "name", "kind": 32, "kindString": "Variable", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "text": "A value of the object.\n" }, @@ -702,7 +745,9 @@ "name": "variableFunction", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "This is a function that is assigned to a variable.", "returns": "This is the return value of the function.\n" @@ -713,7 +758,9 @@ "name": "someParam", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "This is some numeric parameter." }, diff --git a/src/test/converter/implicit-types/specs.json b/src/test/converter/implicit-types/specs.json index b9dc73846..18def2249 100644 --- a/src/test/converter/implicit-types/specs.json +++ b/src/test/converter/implicit-types/specs.json @@ -241,7 +241,9 @@ "name": "getBreakpoints", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reflection", "declaration": { @@ -249,14 +251,18 @@ "name": "__type", "kind": 65536, "kindString": "Type literal", - "flags": {}, + "flags": { + "isExported": true + }, "children": [ { "id": 17, "name": "large", "kind": 32, "kindString": "Variable", - "flags": {}, + "flags": { + "isExported": true + }, "sources": [ { "fileName": "implicit-types.ts", @@ -275,7 +281,9 @@ "name": "medium", "kind": 32, "kindString": "Variable", - "flags": {}, + "flags": { + "isExported": true + }, "sources": [ { "fileName": "implicit-types.ts", @@ -294,7 +302,9 @@ "name": "small", "kind": 32, "kindString": "Variable", - "flags": {}, + "flags": { + "isExported": true + }, "sources": [ { "fileName": "implicit-types.ts", @@ -313,7 +323,9 @@ "name": "xlarge", "kind": 32, "kindString": "Variable", - "flags": {}, + "flags": { + "isExported": true + }, "sources": [ { "fileName": "implicit-types.ts", @@ -332,7 +344,9 @@ "name": "xxlarge", "kind": 32, "kindString": "Variable", - "flags": {}, + "flags": { + "isExported": true + }, "sources": [ { "fileName": "implicit-types.ts", diff --git a/src/test/converter/interface-implementation/specs.json b/src/test/converter/interface-implementation/specs.json index 106372c44..7ae98a3dc 100644 --- a/src/test/converter/interface-implementation/specs.json +++ b/src/test/converter/interface-implementation/specs.json @@ -45,7 +45,9 @@ "name": "T", "kind": 131072, "kindString": "Type parameter", - "flags": {} + "flags": { + "isExported": true + } } ], "children": [ @@ -94,14 +96,18 @@ "name": "add", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 50, "name": "listener", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "IEventListener", @@ -119,7 +125,9 @@ "name": "filter", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "any" @@ -131,7 +139,9 @@ "name": "priority", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" @@ -184,7 +194,9 @@ "name": "clear", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "void" @@ -223,14 +235,18 @@ "name": "dispatch", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 58, "name": "event", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "typeParameter", "name": "T" @@ -275,7 +291,9 @@ "name": "hasListeners", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "boolean" @@ -314,14 +332,18 @@ "name": "remove", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 55, "name": "subscription", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "ISubscription", @@ -721,7 +743,9 @@ "name": "U", "kind": 131072, "kindString": "Type parameter", - "flags": {} + "flags": { + "isExported": true + } } ], "children": [ @@ -739,14 +763,18 @@ "name": "add", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 32, "name": "listener", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "IEventListener", @@ -765,6 +793,7 @@ "kind": 32768, "kindString": "Parameter", "flags": { + "isExported": true, "isOptional": true }, "type": { @@ -778,6 +807,7 @@ "kind": 32768, "kindString": "Parameter", "flags": { + "isExported": true, "isOptional": true }, "type": { @@ -821,7 +851,9 @@ "name": "clear", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "void" @@ -850,14 +882,18 @@ "name": "dispatch", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 40, "name": "parameter", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "typeParameter", "name": "U" @@ -892,7 +928,9 @@ "name": "hasListeners", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "boolean" @@ -921,14 +959,18 @@ "name": "remove", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 37, "name": "subscription", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "ISubscription", diff --git a/src/test/converter/literal-type/literal-type.ts b/src/test/converter/literal-type/literal-type.ts index 99aa5a4c4..ad62e43e9 100644 --- a/src/test/converter/literal-type/literal-type.ts +++ b/src/test/converter/literal-type/literal-type.ts @@ -1,11 +1,31 @@ -let typeLiteral:{ - valueZ:string; - valueY:{():string;}; - valueX:{ - valueZ:string; - valueY:{(z:string):{a:string; b:string}; }; - valueA:number[]; - }; - valueA?:number; - valueB?:boolean; +let typeLiteral: { + valueZ: string; + valueY: {(): string; }; + valueX: { + valueZ: string; + valueY: {(z: string): {a: string; b: string}; }; + valueA: number[]; + }; + valueA?: number; + valueB?: boolean; }; + +export interface NestedInterface { + nestedOptional?: { + innerMember: string; + }; + + nested: { + isIncluded: boolean; + }; +} + +export function func(param: { nested: string }): boolean { + return param.nested === 'yes'; +} + +export function createSomething() { + return { + foo: 'bar' + }; +} diff --git a/src/test/converter/literal-type/specs-without-exported.json b/src/test/converter/literal-type/specs-without-exported.json new file mode 100644 index 000000000..fca06ac33 --- /dev/null +++ b/src/test/converter/literal-type/specs-without-exported.json @@ -0,0 +1,380 @@ +{ + "id": 0, + "name": "typedoc", + "kind": 0, + "flags": {}, + "children": [ + { + "id": 1, + "name": "\"literal-type\"", + "kind": 1, + "kindString": "External module", + "flags": { + "isExported": true + }, + "originalName": "%BASE%/literal-type/literal-type.ts", + "children": [ + { + "id": 2, + "name": "NestedInterface", + "kind": 256, + "kindString": "Interface", + "flags": { + "isExported": true, + "hasExport": true + }, + "children": [ + { + "id": 6, + "name": "nested", + "kind": 1024, + "kindString": "Property", + "flags": { + "isExported": true + }, + "sources": [ + { + "fileName": "literal-type.ts", + "line": 18, + "character": 10 + } + ], + "type": { + "type": "reflection", + "declaration": { + "id": 7, + "name": "__type", + "kind": 65536, + "kindString": "Type literal", + "flags": { + "isExported": true + }, + "children": [ + { + "id": 8, + "name": "isIncluded", + "kind": 32, + "kindString": "Variable", + "flags": { + "isExported": true + }, + "sources": [ + { + "fileName": "literal-type.ts", + "line": 19, + "character": 18 + } + ], + "type": { + "type": "intrinsic", + "name": "boolean" + } + } + ], + "groups": [ + { + "title": "Variables", + "kind": 32, + "children": [ + 8 + ] + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 18, + "character": 11 + } + ] + } + } + }, + { + "id": 3, + "name": "nestedOptional", + "kind": 1024, + "kindString": "Property", + "flags": { + "isExported": true, + "isOptional": true + }, + "sources": [ + { + "fileName": "literal-type.ts", + "line": 14, + "character": 18 + } + ], + "type": { + "type": "reflection", + "declaration": { + "id": 4, + "name": "__type", + "kind": 65536, + "kindString": "Type literal", + "flags": { + "isExported": true + }, + "children": [ + { + "id": 5, + "name": "innerMember", + "kind": 32, + "kindString": "Variable", + "flags": { + "isExported": true + }, + "sources": [ + { + "fileName": "literal-type.ts", + "line": 15, + "character": 19 + } + ], + "type": { + "type": "intrinsic", + "name": "string" + } + } + ], + "groups": [ + { + "title": "Variables", + "kind": 32, + "children": [ + 5 + ] + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 14, + "character": 20 + } + ] + } + } + } + ], + "groups": [ + { + "title": "Properties", + "kind": 1024, + "children": [ + 6, + 3 + ] + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 13, + "character": 32 + } + ] + }, + { + "id": 33, + "name": "createSomething", + "kind": 64, + "kindString": "Function", + "flags": { + "isExported": true, + "hasExport": true + }, + "signatures": [ + { + "id": 34, + "name": "createSomething", + "kind": 4096, + "kindString": "Call signature", + "flags": { + "isExported": true + }, + "type": { + "type": "reflection", + "declaration": { + "id": 35, + "name": "__type", + "kind": 65536, + "kindString": "Type literal", + "flags": { + "isExported": true + }, + "children": [ + { + "id": 36, + "name": "foo", + "kind": 32, + "kindString": "Variable", + "flags": { + "isExported": true + }, + "sources": [ + { + "fileName": "literal-type.ts", + "line": 29, + "character": 11 + } + ], + "type": { + "type": "intrinsic", + "name": "string" + }, + "defaultValue": "\"bar\"" + } + ], + "groups": [ + { + "title": "Variables", + "kind": 32, + "children": [ + 36 + ] + } + ] + } + } + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 27, + "character": 31 + } + ] + }, + { + "id": 28, + "name": "func", + "kind": 64, + "kindString": "Function", + "flags": { + "isExported": true, + "hasExport": true + }, + "signatures": [ + { + "id": 29, + "name": "func", + "kind": 4096, + "kindString": "Call signature", + "flags": { + "isExported": true + }, + "parameters": [ + { + "id": 30, + "name": "param", + "kind": 32768, + "kindString": "Parameter", + "flags": { + "isExported": true + }, + "type": { + "type": "reflection", + "declaration": { + "id": 31, + "name": "__type", + "kind": 65536, + "kindString": "Type literal", + "flags": { + "isExported": true + }, + "children": [ + { + "id": 32, + "name": "nested", + "kind": 32, + "kindString": "Variable", + "flags": { + "isExported": true + }, + "sources": [ + { + "fileName": "literal-type.ts", + "line": 23, + "character": 36 + } + ], + "type": { + "type": "intrinsic", + "name": "string" + } + } + ], + "groups": [ + { + "title": "Variables", + "kind": 32, + "children": [ + 32 + ] + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 23, + "character": 27 + } + ] + } + } + } + ], + "type": { + "type": "intrinsic", + "name": "boolean" + } + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 23, + "character": 20 + } + ] + } + ], + "groups": [ + { + "title": "Interfaces", + "kind": 256, + "children": [ + 2 + ] + }, + { + "title": "Functions", + "kind": 64, + "children": [ + 33, + 28 + ] + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 1, + "character": 0 + } + ] + } + ], + "groups": [ + { + "title": "External modules", + "kind": 1, + "children": [ + 1 + ] + } + ] +} \ No newline at end of file diff --git a/src/test/converter/literal-type/specs.json b/src/test/converter/literal-type/specs.json index 1d4145393..9941d1e8b 100644 --- a/src/test/converter/literal-type/specs.json +++ b/src/test/converter/literal-type/specs.json @@ -16,6 +16,168 @@ "children": [ { "id": 2, + "name": "NestedInterface", + "kind": 256, + "kindString": "Interface", + "flags": { + "isExported": true, + "hasExport": true + }, + "children": [ + { + "id": 6, + "name": "nested", + "kind": 1024, + "kindString": "Property", + "flags": { + "isExported": true + }, + "sources": [ + { + "fileName": "literal-type.ts", + "line": 18, + "character": 10 + } + ], + "type": { + "type": "reflection", + "declaration": { + "id": 7, + "name": "__type", + "kind": 65536, + "kindString": "Type literal", + "flags": { + "isExported": true + }, + "children": [ + { + "id": 8, + "name": "isIncluded", + "kind": 32, + "kindString": "Variable", + "flags": { + "isExported": true + }, + "sources": [ + { + "fileName": "literal-type.ts", + "line": 19, + "character": 18 + } + ], + "type": { + "type": "intrinsic", + "name": "boolean" + } + } + ], + "groups": [ + { + "title": "Variables", + "kind": 32, + "children": [ + 8 + ] + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 18, + "character": 11 + } + ] + } + } + }, + { + "id": 3, + "name": "nestedOptional", + "kind": 1024, + "kindString": "Property", + "flags": { + "isExported": true, + "isOptional": true + }, + "sources": [ + { + "fileName": "literal-type.ts", + "line": 14, + "character": 18 + } + ], + "type": { + "type": "reflection", + "declaration": { + "id": 4, + "name": "__type", + "kind": 65536, + "kindString": "Type literal", + "flags": { + "isExported": true + }, + "children": [ + { + "id": 5, + "name": "innerMember", + "kind": 32, + "kindString": "Variable", + "flags": { + "isExported": true + }, + "sources": [ + { + "fileName": "literal-type.ts", + "line": 15, + "character": 19 + } + ], + "type": { + "type": "intrinsic", + "name": "string" + } + } + ], + "groups": [ + { + "title": "Variables", + "kind": 32, + "children": [ + 5 + ] + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 14, + "character": 20 + } + ] + } + } + } + ], + "groups": [ + { + "title": "Properties", + "kind": 1024, + "children": [ + 6, + 3 + ] + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 13, + "character": 32 + } + ] + }, + { + "id": 9, "name": "typeLiteral", "kind": 32, "kindString": "Variable", @@ -32,14 +194,14 @@ "type": { "type": "reflection", "declaration": { - "id": 3, + "id": 10, "name": "__type", "kind": 65536, "kindString": "Type literal", "flags": {}, "children": [ { - "id": 19, + "id": 26, "name": "valueA", "kind": 32, "kindString": "Variable", @@ -59,7 +221,7 @@ } }, { - "id": 20, + "id": 27, "name": "valueB", "kind": 32, "kindString": "Variable", @@ -79,7 +241,7 @@ } }, { - "id": 8, + "id": 15, "name": "valueX", "kind": 32, "kindString": "Variable", @@ -94,14 +256,14 @@ "type": { "type": "reflection", "declaration": { - "id": 9, + "id": 16, "name": "__type", "kind": 65536, "kindString": "Type literal", "flags": {}, "children": [ { - "id": 18, + "id": 25, "name": "valueA", "kind": 32, "kindString": "Variable", @@ -122,7 +284,7 @@ } }, { - "id": 11, + "id": 18, "name": "valueY", "kind": 32, "kindString": "Variable", @@ -137,21 +299,21 @@ "type": { "type": "reflection", "declaration": { - "id": 12, + "id": 19, "name": "__type", "kind": 65536, "kindString": "Type literal", "flags": {}, "signatures": [ { - "id": 13, + "id": 20, "name": "__call", "kind": 4096, "kindString": "Call signature", "flags": {}, "parameters": [ { - "id": 14, + "id": 21, "name": "z", "kind": 32768, "kindString": "Parameter", @@ -165,14 +327,14 @@ "type": { "type": "reflection", "declaration": { - "id": 15, + "id": 22, "name": "__type", "kind": 65536, "kindString": "Type literal", "flags": {}, "children": [ { - "id": 16, + "id": 23, "name": "a", "kind": 32, "kindString": "Variable", @@ -181,7 +343,7 @@ { "fileName": "literal-type.ts", "line": 6, - "character": 29 + "character": 32 } ], "type": { @@ -190,7 +352,7 @@ } }, { - "id": 17, + "id": 24, "name": "b", "kind": 32, "kindString": "Variable", @@ -199,7 +361,7 @@ { "fileName": "literal-type.ts", "line": 6, - "character": 39 + "character": 43 } ], "type": { @@ -213,8 +375,8 @@ "title": "Variables", "kind": 32, "children": [ - 16, - 17 + 23, + 24 ] } ], @@ -222,7 +384,7 @@ { "fileName": "literal-type.ts", "line": 6, - "character": 27 + "character": 29 } ] } @@ -240,7 +402,7 @@ } }, { - "id": 10, + "id": 17, "name": "valueZ", "kind": 32, "kindString": "Variable", @@ -263,9 +425,9 @@ "title": "Variables", "kind": 32, "children": [ + 25, 18, - 11, - 10 + 17 ] } ], @@ -280,7 +442,7 @@ } }, { - "id": 5, + "id": 12, "name": "valueY", "kind": 32, "kindString": "Variable", @@ -295,14 +457,14 @@ "type": { "type": "reflection", "declaration": { - "id": 6, + "id": 13, "name": "__type", "kind": 65536, "kindString": "Type literal", "flags": {}, "signatures": [ { - "id": 7, + "id": 14, "name": "__call", "kind": 4096, "kindString": "Call signature", @@ -324,7 +486,7 @@ } }, { - "id": 4, + "id": 11, "name": "valueZ", "kind": 32, "kindString": "Variable", @@ -347,11 +509,11 @@ "title": "Variables", "kind": 32, "children": [ - 19, - 20, - 8, - 5, - 4 + 26, + 27, + 15, + 12, + 11 ] } ], @@ -364,14 +526,194 @@ ] } } + }, + { + "id": 33, + "name": "createSomething", + "kind": 64, + "kindString": "Function", + "flags": { + "isExported": true, + "hasExport": true + }, + "signatures": [ + { + "id": 34, + "name": "createSomething", + "kind": 4096, + "kindString": "Call signature", + "flags": { + "isExported": true + }, + "type": { + "type": "reflection", + "declaration": { + "id": 35, + "name": "__type", + "kind": 65536, + "kindString": "Type literal", + "flags": { + "isExported": true + }, + "children": [ + { + "id": 36, + "name": "foo", + "kind": 32, + "kindString": "Variable", + "flags": { + "isExported": true + }, + "sources": [ + { + "fileName": "literal-type.ts", + "line": 29, + "character": 11 + } + ], + "type": { + "type": "intrinsic", + "name": "string" + }, + "defaultValue": "\"bar\"" + } + ], + "groups": [ + { + "title": "Variables", + "kind": 32, + "children": [ + 36 + ] + } + ] + } + } + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 27, + "character": 31 + } + ] + }, + { + "id": 28, + "name": "func", + "kind": 64, + "kindString": "Function", + "flags": { + "isExported": true, + "hasExport": true + }, + "signatures": [ + { + "id": 29, + "name": "func", + "kind": 4096, + "kindString": "Call signature", + "flags": { + "isExported": true + }, + "parameters": [ + { + "id": 30, + "name": "param", + "kind": 32768, + "kindString": "Parameter", + "flags": { + "isExported": true + }, + "type": { + "type": "reflection", + "declaration": { + "id": 31, + "name": "__type", + "kind": 65536, + "kindString": "Type literal", + "flags": { + "isExported": true + }, + "children": [ + { + "id": 32, + "name": "nested", + "kind": 32, + "kindString": "Variable", + "flags": { + "isExported": true + }, + "sources": [ + { + "fileName": "literal-type.ts", + "line": 23, + "character": 36 + } + ], + "type": { + "type": "intrinsic", + "name": "string" + } + } + ], + "groups": [ + { + "title": "Variables", + "kind": 32, + "children": [ + 32 + ] + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 23, + "character": 27 + } + ] + } + } + } + ], + "type": { + "type": "intrinsic", + "name": "boolean" + } + } + ], + "sources": [ + { + "fileName": "literal-type.ts", + "line": 23, + "character": 20 + } + ] } ], "groups": [ + { + "title": "Interfaces", + "kind": 256, + "children": [ + 2 + ] + }, { "title": "Variables", "kind": 32, "children": [ - 2 + 9 + ] + }, + { + "title": "Functions", + "kind": 64, + "children": [ + 33, + 28 ] } ], diff --git a/src/test/converter/mixin/specs.json b/src/test/converter/mixin/specs.json index d4fab83cb..90e63fceb 100644 --- a/src/test/converter/mixin/specs.json +++ b/src/test/converter/mixin/specs.json @@ -62,7 +62,9 @@ "name": "baseMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" @@ -235,7 +237,9 @@ "name": "baseMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" @@ -284,7 +288,9 @@ "name": "classWithMixinMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "string" @@ -313,14 +319,18 @@ "name": "method1", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 39, "name": "arg", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "Mixin1Type", @@ -376,14 +386,18 @@ "name": "method2", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 35, "name": "arg", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "Mixin2" @@ -586,7 +600,9 @@ "name": "baseMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" @@ -635,14 +651,18 @@ "name": "method1", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 11, "name": "arg", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "Mixin1Type", @@ -717,7 +737,9 @@ "name": "__type", "kind": 65536, "kindString": "Type literal", - "flags": {} + "flags": { + "isExported": true + } } } ] @@ -843,7 +865,9 @@ "name": "baseMethod", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "intrinsic", "name": "number" @@ -892,14 +916,18 @@ "name": "method1", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 24, "name": "arg", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "Mixin1Type", @@ -955,14 +983,18 @@ "name": "method2", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 20, "name": "arg", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "Mixin2" @@ -1037,7 +1069,9 @@ "name": "__type", "kind": 65536, "kindString": "Type literal", - "flags": {} + "flags": { + "isExported": true + } } } ] @@ -1071,7 +1105,9 @@ "name": "A", "kind": 131072, "kindString": "Type parameter", - "flags": {} + "flags": { + "isExported": true + } } ], "sources": [ @@ -1088,7 +1124,9 @@ "name": "__type", "kind": 65536, "kindString": "Type literal", - "flags": {}, + "flags": { + "isExported": true + }, "sources": [ { "fileName": "mixin.ts", @@ -1114,7 +1152,9 @@ "name": "A", "kind": 131072, "kindString": "Type parameter", - "flags": {} + "flags": { + "isExported": true + } } ], "sources": [ @@ -1131,14 +1171,18 @@ "name": "__type", "kind": 65536, "kindString": "Type literal", - "flags": {}, + "flags": { + "isExported": true + }, "signatures": [ { "id": 46, "name": "__call", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "parameters": [ { "id": 47, @@ -1146,6 +1190,7 @@ "kind": 32768, "kindString": "Parameter", "flags": { + "isExported": true, "isRest": true }, "type": { @@ -1188,7 +1233,9 @@ "name": "T", "kind": 131072, "kindString": "Type parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "AnyFunction", @@ -1276,7 +1323,9 @@ "name": "Mixin1Func", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "The \"mixin function\" of the Mixin1" }, @@ -1286,7 +1335,9 @@ "name": "T", "kind": 131072, "kindString": "Type parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "AnyConstructor", @@ -1307,7 +1358,9 @@ "name": "base", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "typeParameter", "name": "T", @@ -1368,7 +1421,9 @@ "name": "Mixin2", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "The \"mixin function\" of the Mixin2" }, @@ -1378,7 +1433,9 @@ "name": "T", "kind": 131072, "kindString": "Type parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "AnyConstructor", @@ -1409,7 +1466,9 @@ "name": "base", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "typeParameter", "name": "T", @@ -1480,7 +1539,9 @@ "name": "Mixin3", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "The \"mixin function\" of the Mixin3" }, @@ -1490,7 +1551,9 @@ "name": "T", "kind": 131072, "kindString": "Type parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "reference", "name": "AnyConstructor", @@ -1510,7 +1573,9 @@ "name": "base", "kind": 32768, "kindString": "Parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "typeParameter", "name": "T", diff --git a/src/test/converter/this/specs.json b/src/test/converter/this/specs.json index 96c0cf437..404b5edc4 100644 --- a/src/test/converter/this/specs.json +++ b/src/test/converter/this/specs.json @@ -43,7 +43,9 @@ "name": "chain", "kind": 4096, "kindString": "Call signature", - "flags": {}, + "flags": { + "isExported": true + }, "comment": { "shortText": "Chain method that returns this." }, diff --git a/src/test/converter/type-operator/specs.json b/src/test/converter/type-operator/specs.json index cd0479bc6..e0f2521e7 100644 --- a/src/test/converter/type-operator/specs.json +++ b/src/test/converter/type-operator/specs.json @@ -29,7 +29,9 @@ "name": "T", "kind": 131072, "kindString": "Type parameter", - "flags": {}, + "flags": { + "isExported": true + }, "type": { "type": "typeOperator", "operator": "keyof", diff --git a/src/test/renderer/specs/modules/_functions_.html b/src/test/renderer/specs/modules/_functions_.html index 74233f39f..2b943e0b6 100644 --- a/src/test/renderer/specs/modules/_functions_.html +++ b/src/test/renderer/specs/modules/_functions_.html @@ -132,7 +132,7 @@
foo:
doAnotherThing: function
-
    +
    • doAnotherThing(): void
      @@ -147,7 +147,7 @@

      Returns void
    • doSomething: function
      -
        +
        • doSomething(a: number): number
          diff --git a/src/test/renderer/specs/modules/_typescript_1_4_.html b/src/test/renderer/specs/modules/_typescript_1_4_.html index 167de4fdf..ca0867e63 100644 --- a/src/test/renderer/specs/modules/_typescript_1_4_.html +++ b/src/test/renderer/specs/modules/_typescript_1_4_.html @@ -186,7 +186,7 @@

          Export GenericCallback

          Type declaration

          • -
              +
              • <T>(val: T, index: number, arr: Array<T>): any