@@ -63,8 +63,8 @@ state of the current configuration to build a new one:
63
63
64
64
// define the first configuration
65
65
Encore
66
- .setOutputPath (' web/build/' )
67
- .setPublicPath (' /build' )
66
+ .setOutputPath (' web/build/first_build/ ' )
67
+ .setPublicPath (' /build/first_build ' )
68
68
.addEntry (' app' , ' ./assets/js/app.js' )
69
69
.addStyleEntry (' global' , ' ./assets/css/global.scss' )
70
70
.enableSassLoader ()
@@ -83,8 +83,8 @@ state of the current configuration to build a new one:
83
83
84
84
// define the second configuration
85
85
Encore
86
- .setOutputPath (' web/build/' )
87
- .setPublicPath (' /build' )
86
+ .setOutputPath (' web/build/second_build/ ' )
87
+ .setPublicPath (' /build/second_build ' )
88
88
.addEntry (' mobile' , ' ./assets/js/mobile.js' )
89
89
.addStyleEntry (' mobile' , ' ./assets/css/mobile.less' )
90
90
.enableLessLoader ()
@@ -113,10 +113,10 @@ Next, define the output directories of each build:
113
113
114
114
# app/config/config.yml
115
115
webpack_encore :
116
- output_path : ' %kernel.public_dir %/web/default_build'
116
+ output_path : ' %kernel.project_dir %/web/default_build'
117
117
builds :
118
- firstConfig : ' %kernel.public_dir %/web/first_build'
119
- secondConfig : ' %kernel.public_dir %/web/second_build'
118
+ firstConfig : ' %kernel.project_dir %/web/first_build'
119
+ secondConfig : ' %kernel.project_dir %/web/second_build'
120
120
121
121
Finally, use the third optional parameter of the ``encore_entry_*_tags() ``
122
122
functions to specify which build to use:
0 commit comments