get real version from node_modules
This commit is contained in:
parent
ebc2ac08b7
commit
b7939165d1
2 changed files with 1 additions and 8 deletions
|
@ -6,9 +6,8 @@
|
|||
</template>
|
||||
|
||||
<script>
|
||||
import { getVersion } from '@/utils/index.js'
|
||||
|
||||
const version = getVersion('element-ui') // element-ui version from package.json
|
||||
const version = require('element-ui/package.json').version // element-ui version from node_modules
|
||||
const ORIGINAL_THEME = '#409EFF' // default color
|
||||
|
||||
export default {
|
||||
|
|
|
@ -265,9 +265,3 @@ export function deepClone(source) {
|
|||
}
|
||||
return targetObj
|
||||
}
|
||||
|
||||
// get dependencies verison from package.json
|
||||
export function getVersion(name) {
|
||||
const p = require('../../package')
|
||||
return p.dependencies[name]
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue