File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -245,22 +245,25 @@ export default function vuePlugin(rawOptions: Options = {}): Plugin<Api> {
245245 } ,
246246
247247 config ( config ) {
248+ const isDefineTrue = ( v : unknown ) => v === true || v === 'true'
248249 return {
249250 resolve : {
250251 dedupe : config . build ?. ssr ? [ ] : [ 'vue' ] ,
251252 } ,
252253 define : {
253254 __VUE_OPTIONS_API__ :
254255 options . value . features ?. optionsAPI ??
255- config . define ?. __VUE_OPTIONS_API__ ??
256+ isDefineTrue ( config . define ?. __VUE_OPTIONS_API__ ) ??
256257 true ,
257258 __VUE_PROD_DEVTOOLS__ :
258259 ( options . value . features ?. prodDevtools ||
259- config . define ?. __VUE_PROD_DEVTOOLS__ ) ??
260+ isDefineTrue ( config . define ?. __VUE_PROD_DEVTOOLS__ ) ) ??
260261 false ,
261262 __VUE_PROD_HYDRATION_MISMATCH_DETAILS__ :
262263 ( options . value . features ?. prodHydrationMismatchDetails ||
263- config . define ?. __VUE_PROD_HYDRATION_MISMATCH_DETAILS__ ) ??
264+ isDefineTrue (
265+ config . define ?. __VUE_PROD_HYDRATION_MISMATCH_DETAILS__ ,
266+ ) ) ??
264267 false ,
265268 } ,
266269 ssr : {
You can’t perform that action at this time.
0 commit comments