| | |
| | | ### From CDN or without a Bundler |
| | | |
| | | - **`vue(.runtime).global(.prod).js`**: |
| | | |
| | | - For direct use via `<script src="...">` in the browser. Exposes the `Vue` global. |
| | | - Note that global builds are not [UMD](https://github.com/umdjs/umd) builds. They are built as [IIFEs](https://developer.mozilla.org/en-US/docs/Glossary/IIFE) and is only meant for direct use via `<script src="...">`. |
| | | - Note that global builds are not [UMD](https://github.com/umdjs/umd) builds. They are built as [IIFEs](https://developer.mozilla.org/en-US/docs/Glossary/IIFE) and are only meant for direct use via `<script src="...">`. |
| | | - In-browser template compilation: |
| | | - **`vue.global.js`** is the "full" build that includes both the compiler and the runtime so it supports compiling templates on the fly. |
| | | - **`vue.runtime.global.js`** contains only the runtime and requires templates to be pre-compiled during a build step. |
| | |
| | | ### With a Bundler |
| | | |
| | | - **`vue(.runtime).esm-bundler.js`**: |
| | | |
| | | - For use with bundlers like `webpack`, `rollup` and `parcel`. |
| | | - Leaves prod/dev branches with `process.env.NODE_ENV` guards (must be replaced by bundler) |
| | | - Does not ship minified builds (to be done together with the rest of the code after bundling) |
| | |
| | | `esm-bundler` builds of Vue expose global feature flags that can be overwritten at compile time: |
| | | |
| | | - `__VUE_OPTIONS_API__` |
| | | |
| | | - Default: `true` |
| | | - Enable / disable Options API support |
| | | |
| | | - `__VUE_PROD_DEVTOOLS__` |
| | | |
| | | - Default: `false` |
| | | - Enable / disable devtools support in production |
| | | |