allow to pass element directly
This commit is contained in:
parent
93f64b034f
commit
54c4891fd2
|
|
@ -26,7 +26,11 @@ function loadModules() {
|
|||
<Component />
|
||||
</React.Suspense>
|
||||
)
|
||||
ReactDOM.render(<Root />, document.querySelector(route.el))
|
||||
if (typeof route.el === 'string') {
|
||||
ReactDOM.render(<Root />, document.querySelector(route.el))
|
||||
} else {
|
||||
ReactDOM.render(<Root />, route.el)
|
||||
}
|
||||
}
|
||||
if (route.component) {
|
||||
Vue.prototype.$route = new RegExp(`^${route.path}$`, 'i').exec(blessing.route)
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user