@@ -64,8 +64,6 @@ import { createHydrationFunctions, RootHydrateFunction } from './hydration'
64
64
import { invokeDirectiveHook } from './directives'
65
65
import { startMeasure , endMeasure } from './profiling'
66
66
67
- const __HMR__ = __BUNDLER__ && __DEV__
68
-
69
67
export interface Renderer < HostElement = any > {
70
68
render : RootRenderFunction < HostElement >
71
69
createApp : CreateAppFunction < HostElement >
@@ -660,7 +658,7 @@ function baseCreateRenderer(
660
658
invokeDirectiveHook ( n2 , n1 , parentComponent , 'beforeUpdate' )
661
659
}
662
660
663
- if ( __HMR__ && parentComponent && parentComponent . renderUpdated ) {
661
+ if ( __DEV__ && parentComponent && parentComponent . renderUpdated ) {
664
662
// HMR updated, force full diff
665
663
patchFlag = 0
666
664
optimized = false
@@ -884,7 +882,7 @@ function baseCreateRenderer(
884
882
optimized = true
885
883
}
886
884
887
- if ( __HMR__ && parentComponent && parentComponent . renderUpdated ) {
885
+ if ( __DEV__ && parentComponent && parentComponent . renderUpdated ) {
888
886
// HMR updated, force full diff
889
887
patchFlag = 0
890
888
optimized = false
@@ -987,7 +985,7 @@ function baseCreateRenderer(
987
985
parentSuspense
988
986
) )
989
987
990
- if ( __HMR__ && instance . type . __hmrId ) {
988
+ if ( __DEV__ && instance . type . __hmrId ) {
991
989
registerHMR ( instance )
992
990
}
993
991
@@ -1807,7 +1805,7 @@ function baseCreateRenderer(
1807
1805
parentSuspense : SuspenseBoundary | null ,
1808
1806
doRemove ?: boolean
1809
1807
) => {
1810
- if ( __HMR__ && instance . type . __hmrId ) {
1808
+ if ( __DEV__ && instance . type . __hmrId ) {
1811
1809
unregisterHMR ( instance )
1812
1810
}
1813
1811
0 commit comments