Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

babel-preset-kyt-core

Package Overview
Dependencies
Maintainers
3
Versions
266
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

babel-preset-kyt-core

An opinionated babel preset, best used with kyt

  • 0.3.0-alpha.9
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
7K
increased by0.37%
Maintainers
3
Weekly downloads
 
Created
Source

babel-preset-kyt-core

npm

An opinionated Babel preset, best used with kyt.

This preset is used as a default if a kyt project does not include a .babelrc It is also included as part of babel-preset-kyt-react

To install:

  1. npm install babel-preset-kyt-core --save
  2. In babelrc:
  {
    presets: [
      "babel-preset-kyt-core"
    ]
  }

Options

(see documentation for Babel preset options)

CHANGELOG

0.3.0-alpha.6 - 10/06/17

  • Adds babel-preset-env useBuiltIns option to take advantage of only polyfilling server builds. To take advantage of this functionality, you need to add babel-polyfill as a dependency and import it at the top of src/server/index.js.

0.3.0-alpha.5 - 10/03/17

  • Adds babel-preset-env useBuiltIns option to take advantage of only polyfilling what's needed. To take advantage of this functionality, you need to add babel-polyfill as a dependency and import it at the top of src/client/index.js.

0.3.0-alpha.4 - 09/19/17

  • Removes default node environment when KYT_ENV_TYPE=test.

0.3.0-alpha.3 - 09/19/17

  • Adds KYT_ENV_TYPE=test support for test runs. Similar to the client/server options, the test option can be overridden in envOptions.

0.3.0-alpha.2 - 09/18/17

  • Fixes bugs introduced in the 0.3.0-alpha.1 release where user envOptions overrides were not being deeply merged and the uglify option was not nested in the targets param.

0.3.0-alpha.1 - 09/17/17

  • Replaces babel-preset-latest with babel-preset-env. By default, the following client preset-env browser targets are used:
modules: false,
targets: {
  browsers: ['>1%', 'last 4 versions', 'not ie < 11']
}

Which at the timing of this release, targets the following browsers/OSs:

{
  "chrome": "49",
  "android": "4.2",
  "edge": "12",
  "firefox": "52",
  "ie": "11",
  "ios": "9",
  "safari": "9"
}

If you need to target the server, then you can set process.env.KYT_ENV_TYPE to server. The following preset-env server targets are used:

modules: false,
targets: {
  node: true
}

You can extend the default preset-env client/server targets by passing in your own options into a .babelrc configuration under a envOptions key. For example:

{
  "presets": [
    [
      "kyt-core", {
        "envOptions": {
          "client": {
            "debug": true,
            "targets": {
              "browsers": ["last 2 versions"]
            }
          },
          "server": {
            "modules": true,
            "targets": { "node": false }
          },
        },
      },
    ],
  ],
}

0.2.0 - 03/23/17

Keywords

FAQs

Package last updated on 18 Oct 2017

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc