We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent bc2c66f commit e10c8e7Copy full SHA for e10c8e7
src/router.js
@@ -4,7 +4,7 @@ import IonVueRouter from './components/ion-vue-router.vue'
4
let globalVue = null
5
let globalVueRouter = null
6
7
-if (typeof window !== 'undefined') {
+if (typeof window !== 'undefined' && window.Vue !== undefined) {
8
globalVue = window.Vue
9
globalVueRouter = window.VueRouter
10
} else if (typeof global !== 'undefined') {
test/router.node.spec.js
@@ -0,0 +1,9 @@
1
+import Vue from 'vue'
2
+
3
+describe('asd', () => {
+ it('qqq', () => {
+ window.Vue = undefined
+ global.Vue = Vue
+ require('../src/router.js')
+ })
+})
0 commit comments