@oclif/plugin-help
Advanced tools
Comparing version 3.2.1 to 3.2.2
@@ -0,1 +1,8 @@ | ||
## [3.2.2](https://github.com/oclif/plugin-help/compare/v3.2.1...v3.2.2) (2021-02-03) | ||
### Bug Fixes | ||
* avoid recomputing topics in loop ([#189](https://github.com/oclif/plugin-help/issues/189)) ([eccb862](https://github.com/oclif/plugin-help/commit/eccb862e725f28d305de5cccde109c15abbb5f98)), closes [#101](https://github.com/oclif/plugin-help/issues/101) | ||
## [3.2.1](https://github.com/oclif/plugin-help/compare/v3.2.0...v3.2.1) (2020-12-14) | ||
@@ -2,0 +9,0 @@ |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
const chalk_1 = require("chalk"); | ||
const chalk = require("chalk"); | ||
const indent = require("indent-string"); | ||
@@ -8,6 +8,6 @@ const stripAnsi = require("strip-ansi"); | ||
const util_1 = require("./util"); | ||
const { underline, bold, } = chalk_1.default; | ||
let { dim, } = chalk_1.default; | ||
const { underline, bold, } = chalk; | ||
let { dim, } = chalk; | ||
if (process.env.ConEmuANSI === 'ON') { | ||
dim = chalk_1.default.gray; | ||
dim = chalk.gray; | ||
} | ||
@@ -14,0 +14,0 @@ const wrap = require('wrap-ansi'); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
const errors_1 = require("@oclif/errors"); | ||
const chalk_1 = require("chalk"); | ||
const chalk = require("chalk"); | ||
const indent = require("indent-string"); | ||
@@ -15,3 +15,3 @@ const stripAnsi = require("strip-ansi"); | ||
const wrap = require('wrap-ansi'); | ||
const { bold, } = chalk_1.default; | ||
const { bold, } = chalk; | ||
const ROOT_INDEX_CMD_ID = ''; | ||
@@ -48,5 +48,8 @@ function getHelpSubject(args) { | ||
get _topics() { | ||
return this.config.topics.filter((topic) => { | ||
// since this.config.topics is a getter that does non-trivial work, cache it outside the filter loop for | ||
// performance benefits in the presence of large numbers of topics | ||
const topics = this.config.topics; | ||
return topics.filter((topic) => { | ||
// it is assumed a topic has a child if it has children | ||
const hasChild = this.config.topics.some(subTopic => subTopic.name.includes(`${topic.name}:`)); | ||
const hasChild = topics.some(subTopic => subTopic.name.includes(`${topic.name}:`)); | ||
return hasChild; | ||
@@ -53,0 +56,0 @@ }); |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
const chalk_1 = require("chalk"); | ||
const chalk = require("chalk"); | ||
const indent = require("indent-string"); | ||
@@ -8,3 +8,3 @@ const stripAnsi = require("strip-ansi"); | ||
const wrap = require('wrap-ansi'); | ||
const { bold, } = chalk_1.default; | ||
const { bold, } = chalk; | ||
class RootHelp { | ||
@@ -11,0 +11,0 @@ constructor(config, opts) { |
@@ -1,1 +0,1 @@ | ||
{"version":"3.2.1","commands":{"help":{"id":"help","description":"display help for <%= config.bin %>","pluginName":"@oclif/plugin-help","pluginType":"core","aliases":[],"flags":{"all":{"name":"all","type":"boolean","description":"see all commands in CLI","allowNo":false}},"args":[{"name":"command","description":"command to show help for","required":false}]}}} | ||
{"version":"3.2.2","commands":{"help":{"id":"help","description":"display help for <%= config.bin %>","pluginName":"@oclif/plugin-help","pluginType":"core","aliases":[],"flags":{"all":{"name":"all","type":"boolean","description":"see all commands in CLI","allowNo":false}},"args":[{"name":"command","description":"command to show help for","required":false}]}}} |
{ | ||
"name": "@oclif/plugin-help", | ||
"description": "standard help for oclif", | ||
"version": "3.2.1", | ||
"version": "3.2.2", | ||
"author": "Jeff Dickey @jdxcode", | ||
@@ -11,3 +11,3 @@ "bugs": "https://github.com/oclif/plugin-help/issues", | ||
"@oclif/errors": "^1.2.2", | ||
"chalk": "^2.4.1", | ||
"chalk": "^4.1.0", | ||
"indent-string": "^4.0.0", | ||
@@ -39,3 +39,3 @@ "lodash.template": "^4.4.0", | ||
"sinon": "^9.0.1", | ||
"ts-node": "^8.8.2", | ||
"ts-node": "^9.1.1", | ||
"typescript": "3.8.3" | ||
@@ -42,0 +42,0 @@ }, |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
50105
748
- Removedchalk@2.4.2(transitive)
- Removedescape-string-regexp@1.0.5(transitive)
- Removedhas-flag@3.0.0(transitive)
- Removedsupports-color@5.5.0(transitive)
Updatedchalk@^4.1.0