deprecate.js 614 B

123456789101112
  1. const chalk = require('chalk')
  2. const logger = require('./logger')
  3. const replace = (oldThing, newThing) => {
  4. logger.warn(chalk.bold.yellow('Deprecation Warning:'), '\n')
  5. logger.warn(chalk.yellow(`Option ${chalk.bold(`"${oldThing}"`)} has been removed, and replaced by ${chalk.bold(`"${newThing}"`)}`), '\n')
  6. logger.warn(chalk.yellow('This option will be removed in the next major version of `vue-jest`. Please update your configuration.'), '\n')
  7. logger.warn(chalk.bold.yellow('Configuration Documentation:'))
  8. logger.warn(chalk.yellow('https://github.com/vuejs/vue-jest'))
  9. }
  10. module.exports = { replace }