@@ -7,7 +7,7 @@ import { callHook } from '../init/lifecycle';
7
7
import { getAndActive , sticky } from '../event/sidebar' ;
8
8
import { getPath , isAbsolutePath } from '../router/util' ;
9
9
import { isMobile , inBrowser } from '../util/env' ;
10
- import { isPrimitive } from '../util/core' ;
10
+ import { isPrimitive , merge } from '../util/core' ;
11
11
import { scrollActiveSidebar } from '../event/scroll' ;
12
12
import { Compiler } from './compiler' ;
13
13
import * as tpl from './tpl' ;
@@ -116,10 +116,10 @@ function renderMain(html) {
116
116
117
117
// vueMounts
118
118
vueMountData . push (
119
- ...Object . entries ( docsifyConfig . vueMounts || { } )
120
- . map ( ( [ cssSelector , vueConfig ] ) => [
119
+ ...Object . keys ( docsifyConfig . vueMounts || { } )
120
+ . map ( cssSelector => [
121
121
dom . find ( markdownElm , cssSelector ) ,
122
- vueConfig ,
122
+ docsifyConfig . vueMounts [ cssSelector ] ,
123
123
] )
124
124
. filter ( ( [ elm , vueConfig ] ) => elm )
125
125
) ;
@@ -169,10 +169,7 @@ function renderMain(html) {
169
169
} )
170
170
. map ( elm => {
171
171
// Clone global configuration
172
- const vueConfig = Object . assign (
173
- { } ,
174
- docsifyConfig . vueGlobalOptions || { }
175
- ) ;
172
+ const vueConfig = merge ( { } , docsifyConfig . vueGlobalOptions || { } ) ;
176
173
177
174
// Replace vueGlobalOptions data() return value with shared data object.
178
175
// This provides a global store for all Vue instances that receive
0 commit comments