build: export runtime-only build for bundlers by default in main vue package

This commit is contained in:
Evan You
2019-12-17 18:24:01 -05:00
parent 9550302df4
commit 5cf7523787
5 changed files with 35 additions and 18 deletions

View File

@@ -3,7 +3,7 @@
"version": "3.0.0-alpha.0",
"description": "vue",
"main": "index.js",
"module": "dist/vue.esm-bundler.js",
"module": "dist/vue.runtime.esm-bundler.js",
"files": [
"index.js",
"dist"
@@ -14,6 +14,7 @@
"name": "Vue",
"formats": [
"esm-bundler",
"esm-bundler-runtime",
"cjs",
"global",
"esm"

View File

@@ -0,0 +1,6 @@
if (__BROWSER__ && __DEV__) {
console[console.info ? 'info' : 'log'](
`You are running a development build of Vue.\n` +
`Make sure to use the production build (*.prod.js) when deploying for production.`
)
}

View File

@@ -1,4 +1,4 @@
// This package is the "full-build" that includes both the runtime
// This entry is the "full-build" that includes both the runtime
// and the compiler, and supports on-the-fly compilation of the template option.
import { compile, CompilerOptions, CompilerError } from '@vue/compiler-dom'
import { registerRuntimeCompiler, RenderFunction, warn } from '@vue/runtime-dom'
@@ -61,9 +61,4 @@ registerRuntimeCompiler(compileToFunction)
export { compileToFunction as compile }
export * from '@vue/runtime-dom'
if (__BROWSER__ && __DEV__) {
console[console.info ? 'info' : 'log'](
`You are running a development build of Vue.\n` +
`Make sure to use the production build (*.prod.js) when deploying for production.`
)
}
import './devCheck'

View File

@@ -0,0 +1,6 @@
// This entry exports the runtime only, and is built as
// `dist/vue.esm-bundler.js` which is used by default for bundlers.
export * from '@vue/runtime-dom'
import './devCheck'