refactor: ✨ 移除无用的 get 方法
This commit is contained in:
@@ -1,4 +1,3 @@
|
|||||||
import { get } from 'lodash'
|
|
||||||
import d2Source from './components/d2-source.vue'
|
import d2Source from './components/d2-source.vue'
|
||||||
|
|
||||||
const containers = {
|
const containers = {
|
||||||
@@ -29,7 +28,7 @@ export default {
|
|||||||
computed: {
|
computed: {
|
||||||
// 始终返回渲染组件
|
// 始终返回渲染组件
|
||||||
component () {
|
component () {
|
||||||
return get(containers, `${this.type}${this.betterScroll ? 'bs' : ''}`, 'div')
|
return containers[`${this.type}${this.betterScroll ? 'bs' : ''}`] || 'div'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
render (h) {
|
render (h) {
|
||||||
|
|||||||
Reference in New Issue
Block a user