Skip to content
Snippets Groups Projects
Commit 0f530411 authored by Pan's avatar Pan
Browse files

fix:fixed theme-picker bug

parent dd3e22d5
No related branches found
No related tags found
No related merge requests found
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
<script> <script>
import { getVersion } from '@/utils/index.js' import { getVersion } from '@/utils/index.js'
const version = getVersion('element-ui') // element-ui version from package.json const version = getVersion('element-ui') // element-ui version from package.json
const ORIGINAL_THEME = '#409EFF' // default color const ORIGINAL_THEME = '#409EFF' // default color
......
...@@ -266,9 +266,8 @@ export function deepClone(source) { ...@@ -266,9 +266,8 @@ export function deepClone(source) {
return targetObj return targetObj
} }
// get dependencies verison from package.json by webpack.DefinePlugin // get dependencies verison from package.json
export function getVersion(name) { export function getVersion(name) {
import('../../package').then(p => { const p = require('../../package')
return p.dependencies[name] return p.dependencies[name]
})
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment