Skip to content

Commit 17ec50f

Browse files
committed
fix: fix postinstall script
1 parent 6c5e56a commit 17ec50f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

scripts/postinstall.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@ const fs = require('fs')
44
const path = require('path')
55
const pkg = require('../package.json')
66

7-
const isVue2 = +vue.version.split('.') === 2
7+
const version = vue.version
8+
const isVue2 = +version.split('.')[0] === 2
89

910
if (isVue2) {
1011
console.log('[G2Plot-Vue] Switch main field for Vue 2')

0 commit comments

Comments
 (0)