提交 | 用户 | age | ||
aeb317 | 1 | import Vue from 'vue' |
J | 2 | import SvgIcon from '@/components/SvgIcon'// svg component |
3 | ||
4 | // register globally | |
5 | Vue.component('svg-icon', SvgIcon) | |
6 | ||
7 | const req = require.context('./svg', false, /\.svg$/) | |
8 | const requireAll = requireContext => requireContext.keys().map(requireContext) | |
9 | requireAll(req) |