Babel Preset for Vue Applications

2.0.0 · maintenance · verified Wed Apr 22

The `babel-preset-vue-app` package provides a consolidated Babel preset specifically tailored for Vue.js applications. Currently at version 2.0.0, this preset simplifies Babel configuration by integrating `babel-preset-env` for efficient polyfilling and targeting various JavaScript environments, and `babel-plugin-transform-runtime` to avoid polluting the global scope with polyfills. It additionally includes support for transforming Vue JSX, ES features like object rest/spread properties, dynamic imports, and modern `async/await` syntax. This preset aims to offer an opinionated, ready-to-use configuration for Vue projects, often serving as a foundational element in build setups from older Vue CLI versions or custom configurations. Its release cadence is primarily driven by updates to its underlying Babel dependencies. A key differentiator is its comprehensive, single-package approach to common Vue Babel needs, contrasting with a manual assembly of individual Babel plugins and presets.

Common errors

Warnings

Install

Imports

Quickstart

Shows the minimal `.babelrc` configuration to enable the `babel-preset-vue-app`.

{
  "presets": [
    "vue-app"
  ]
}

view raw JSON →