@@ -75,14 +75,24 @@ const builds = {
7575 format : 'es' ,
7676 banner
7777 } ,
78- // Runtime+compiler CommonJS build (ES Modules )
78+ // Runtime+compiler ES modules build (for bundlers )
7979 'web-full-esm' : {
8080 entry : resolve ( 'web/entry-runtime-with-compiler.js' ) ,
8181 dest : resolve ( 'dist/vue.esm.js' ) ,
8282 format : 'es' ,
8383 alias : { he : './entity-decoder' } ,
8484 banner
8585 } ,
86+ // Runtime+compiler ES modules build (for direct import in browser)
87+ 'web-full-esm-browser' : {
88+ entry : resolve ( 'web/entry-runtime-with-compiler.js' ) ,
89+ dest : resolve ( 'dist/vue.esm.browser.js' ) ,
90+ format : 'es' ,
91+ transpile : false ,
92+ env : 'development' ,
93+ alias : { he : './entity-decoder' } ,
94+ banner
95+ } ,
8696 // runtime-only build (Browser)
8797 'web-runtime-dev' : {
8898 entry : resolve ( 'web/entry-runtime.js' ) ,
@@ -205,7 +215,6 @@ function genConfig (name) {
205215 __VERSION__ : version
206216 } ) ,
207217 flow ( ) ,
208- buble ( ) ,
209218 alias ( Object . assign ( { } , aliases , opts . alias ) )
210219 ] . concat ( opts . plugins || [ ] ) ,
211220 output : {
@@ -227,6 +236,10 @@ function genConfig (name) {
227236 } ) )
228237 }
229238
239+ if ( opts . transpile !== false ) {
240+ config . plugins . push ( buble ( ) )
241+ }
242+
230243 Object . defineProperty ( config , '_name' , {
231244 enumerable : false ,
232245 value : name
0 commit comments