提交 | 用户 | age | ||
2a61f6 | 1 | import Vue from 'vue' |
L | 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) |