@kiwicom/babel-preset

0.2.6 • Public • Published

@kiwicom/babel-preset

Kiwi.com's official Babel preset for our customer-facing apps. Works for Node and Webpack.

Setup

babel.config.js

module.exports = {
  presets: ["@kiwicom"],
};

Contains:

  • TypeScript
  • React
  • Styled components
  • Orbit components

Assumes:

  • absolute paths relative to the ./src (adjustable by babel-plugin-module-resolver)
  • using __DEV__ expressions as a process.env.NODE_ENV check

Configuration

You can adjust the options for @babel/preset-env as follows:

module.exports = {
  presets: [
    [
      "@kiwicom",
      {
        "preset-env": {
          // options accepted by preset-env, for example:
          target: { node: "current" },
        },
      },
    ],
  ],
};

License

MIT

Readme

Keywords

none

Package Sidebar

Install

npm i @kiwicom/babel-preset

Weekly Downloads

228

Version

0.2.6

License

MIT

Unpacked Size

5.24 kB

Total Files

4

Last publish

Collaborators

  • mvidalgarcia
  • dsil
  • jakubzaba
  • robincsl_kiwi
  • kiwicom.platform
  • dinodsaurus