Nagging Penguin Matriarchs

    read-babelrc-up

    1.1.0 • Public • Published

    read-babelrc-up

    Build Status styled with prettier All Contributors

    Read the closet Babel configuration file or babel in package.json.

    Install

    $ npm install --save read-babelrc-up
    

    Usage

    const readBabelrcUp = require('read-babelrc-up')
     
    readBabelrcUp().then(result => {
      console.log(result)
      /*
      {
        babel:
         { presets: [ 'es2015', 'react' ],
          plugins: [ 'transform-class-properties' ] },
        path: '/Users/akameco/src/my-babel-app/.babelrc'
      }
      */
    })

    API

    readBabelrcUp([options])

    Returns a Promise for the result object.

    readBabelrcUp.sync([options])

    Return the result object.

    options

    cwd

    Type: string
    Default: .

    Directory to start looking for .babelrc file.

    Related

    • find-up - Find a file by walking up parent directories

    Contributors

    Thanks goes to these wonderful people (emoji key):


    akameco

    💻 📖 ⚠️ 🚇

    Jiyoon Jang

    💻 ⚠️

    This project follows the all-contributors specification. Contributions of any kind welcome!

    License

    MIT © akameco

    Install

    npm i read-babelrc-up

    DownloadsWeekly Downloads

    16,012

    Version

    1.1.0

    License

    MIT

    Unpacked Size

    6.86 kB

    Total Files

    5

    Last publish

    Collaborators

    • akameco