How to use the @babel/cli/lib/babel/dir.js.default function in @babel/cli

To help you get started, we’ve selected a few @babel/cli 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 FelixKuehl / cra-monorepo / packages / library-utils / bin / start.js View on Github external
// Spawn Babel server
  process.env.NODE_ENV = 'development'
  const opts = parseArgv([
    process.argv[0],
    process.argv[1],
    '-w',
    '--presets=react-app',
    'src',
    '--out-dir',
    'es',
    '--copy-files',
    '--delete-dir-on-start',
    '--ignore',
    '__tests__,spec.js,test.js,__snapshots__'
  ])
  dirCommand(opts).catch(err => {
    console.error(err)
    process.exit(1)
  })
  if (type === 'withStorybook') {
    startStyleguide()
  }
  printDevServerInfo()
}
module.exports = {startDev}

@babel/cli

Babel command line.

MIT
Latest version published 17 days ago

Package Health Score

83 / 100
Full package analysis