<script src="...">in the browser. Exposes the
vue.global.jsis the "full" build that includes both the compiler and the runtime so it supports compiling templates on the fly.
vue.runtime.global.jscontains only the runtime and requires templates to be pre-compiled during a build step.
*.prod.jsfiles for production.
process.env.NODE_ENVguards (must be replaced by bundler)
esm-bundlerbuilds and will in turn import their dependencies (e.g.
vue.runtime.esm-bundler.js(default) is runtime only, and requires all templates to be pre-compiled. This is the default entry for bundlers (via
package.json) because when using a bundler templates are typically pre-compiled (e.g. in
vueto this file.
Starting with 3.0.0-rc.3,
esm-bundler builds now exposes global feature flags that can be overwritten at compile time:
__VUE_OPTIONS_API__(enable/disable Options API support, default:
__VUE_PROD_DEVTOOLS__(enable/disable devtools support in production, default:
The build will work without configuring these flags, however it is strongly recommended to properly configure them in order to get proper tree-shaking in the final bundle. To configure these flags:
Note: the replacement value must be boolean literals and cannot be strings, otherwise the bundler/minifier will not be able to properly evaluate the conditions.
target: 'node'and properly externalize
vue, this is the build that will be loaded.
The npm package vue receives a total of 2,539,883 weekly downloads. As such, vue popularity was classified as popular.
We found that vue demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago.It has 2 open source maintainers collaborating on the project.