How to use the @istanbuljs/load-nyc-config.loadNycConfig function in @istanbuljs/load-nyc-config

To help you get started, we’ve selected a few @istanbuljs/load-nyc-config examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github istanbuljs / nyc / lib / config-util.js View on Github external
    .example('$0 npm test', 'instrument your tests with coverage')
    .example('$0 --require @babel/register npm test', 'instrument your tests with coverage and transpile with Babel')
    .example('$0 report --reporter=text-lcov', 'output lcov report after running your tests')
    .epilog('visit for list of available reporters')

  const instrumenterArgs = processArgs.hideInstrumenteeArgs()

  // This yargs.parse must come before any options that exit post-hoc
  const childArgs = processArgs.hideInstrumenterArgs(yargs.parse(process.argv.slice(2)))
  const config = await loadNycConfig(yargs.parse(instrumenterArgs))

    .alias('h', 'help')

  return {
    get argv () {
      return yargs.parse(instrumenterArgs)


Utility function to load nyc configuration

Latest version published 4 years ago

Package Health Score

68 / 100
Full package analysis

Popular @istanbuljs/load-nyc-config functions

Similar packages