@storybook/node-logger
Advanced tools
Comparing version 4.1.0-alpha.1 to 4.1.0-alpha.2
@@ -8,11 +8,29 @@ "use strict"; | ||
}); | ||
exports.logger = void 0; | ||
exports.logger = exports.colors = void 0; | ||
var _npmlog = _interopRequireDefault(require("npmlog")); | ||
var _prettyHrtime = _interopRequireDefault(require("pretty-hrtime")); | ||
var _chalk = _interopRequireDefault(require("chalk")); | ||
const colors = { | ||
pink: _chalk.default.hex('F1618C'), | ||
purple: _chalk.default.hex('B57EE5'), | ||
orange: _chalk.default.hex('F3AD38'), | ||
green: _chalk.default.hex('A2E05E'), | ||
blue: _chalk.default.hex('6DABF5'), | ||
red: _chalk.default.hex('F16161'), | ||
gray: _chalk.default.gray | ||
}; | ||
exports.colors = colors; | ||
const logger = { | ||
info: message => _npmlog.default.info('', message), | ||
warn: message => _npmlog.default.warn('', message), | ||
error: message => _npmlog.default.error('', message) | ||
error: message => _npmlog.default.error('', message), | ||
trace: ({ | ||
message, | ||
time | ||
}) => _npmlog.default.info(`${message} (${colors.purple((0, _prettyHrtime.default)(time))})`) | ||
}; | ||
exports.logger = logger; |
{ | ||
"name": "@storybook/node-logger", | ||
"version": "4.1.0-alpha.1", | ||
"version": "4.1.0-alpha.2", | ||
"description": "", | ||
@@ -27,5 +27,7 @@ "keywords": [ | ||
"@babel/runtime": "^7.1.2", | ||
"npmlog": "^4.1.2" | ||
"chalk": "^2.4.1", | ||
"npmlog": "^4.1.2", | ||
"pretty-hrtime": "^1.0.3" | ||
}, | ||
"gitHead": "253a667e68bac7dee4d97a6bcca020b7d05617e6" | ||
"gitHead": "cdb9e485eb85690368b1f698db9220ca7bc0298e" | ||
} |
import npmLog from 'npmlog'; | ||
import prettyTime from 'pretty-hrtime'; | ||
import chalk from 'chalk'; | ||
export const colors = { | ||
pink: chalk.hex('F1618C'), | ||
purple: chalk.hex('B57EE5'), | ||
orange: chalk.hex('F3AD38'), | ||
green: chalk.hex('A2E05E'), | ||
blue: chalk.hex('6DABF5'), | ||
red: chalk.hex('F16161'), | ||
gray: chalk.gray, | ||
}; | ||
export const logger = { | ||
@@ -7,2 +19,3 @@ info: message => npmLog.info('', message), | ||
error: message => npmLog.error('', message), | ||
trace: ({ message, time }) => npmLog.info(`${message} (${colors.purple(prettyTime(time))})`), | ||
}; |
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
5664
105
4
+ Addedchalk@^2.4.1
+ Addedpretty-hrtime@^1.0.3
+ Addedansi-styles@3.2.1(transitive)
+ Addedchalk@2.4.2(transitive)
+ Addedcolor-convert@1.9.3(transitive)
+ Addedcolor-name@1.1.3(transitive)
+ Addedescape-string-regexp@1.0.5(transitive)
+ Addedhas-flag@3.0.0(transitive)
+ Addedpretty-hrtime@1.0.3(transitive)
+ Addedsupports-color@5.5.0(transitive)