Browse Source

fix(icon): fix the warning of not export default at webpack5 (#4579)

pull/4597/head
BeADre 3 years ago committed by GitHub
parent
commit
7b317a2765
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 8
      components/icon/index.js

8
components/icon/index.js

@ -19,9 +19,11 @@ import Base from '../base';
// Initial setting
// https://github.com/vueComponent/ant-design-vue/issues/2745
let validIcons = allIcons.default || allIcons;
VueIcon.add(...Object.keys(validIcons).map(key => validIcons[key]));
VueIcon.add(
...Object.keys(allIcons)
.filter(key => key !== 'default')
.map(key => allIcons[key]),
);
setTwoToneColor('#1890ff');
const defaultTheme = 'outlined';
let dangerousTheme;

Loading…
Cancel
Save