diff --git a/index.js b/index.js index aa83de8..d04ce95 100644 --- a/index.js +++ b/index.js @@ -41,7 +41,7 @@ function chalkFactory(options) { Object.setPrototypeOf(chalk.template, chalk); chalk.template.constructor = () => { - throw new Error('Chalk.constructor() is deprecated. Use new Chalk.Instance() instead.'); + throw new Error('`chalk.constructor()` is deprecated. Use `new chalk.Instance()` instead.'); }; chalk.template.Instance = ChalkClass; diff --git a/readme.md b/readme.md index 4447ad5..1a5672c 100644 --- a/readme.md +++ b/readme.md @@ -140,7 +140,7 @@ Multiple arguments will be separated by space. Color support is automatically detected, as is the level (see `chalk.level`). However, if you'd like to simply enable/disable Chalk, you can do so via the `.enabled` property. When `chalk.enabled` is `true`, `chalk.level` must *also* be greater than `0` for colored output to be produced. -Chalk is enabled by default unless explicitly disabled via `Chalk.Instance()` or `chalk.level` is `0`. +Chalk is enabled by default unless explicitly disabled via `new chalk.Instance()` or `chalk.level` is `0`. If you need to change this in a reusable module, create a new instance: