import type { App } from 'vue'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'

export const elIcons = ElementPlusIconsVue
export type ElIconType = keyof typeof ElementPlusIconsVue

const install = (app: App): void => {
  for (const [ key, component ] of Object.entries(ElementPlusIconsVue)) {
    app.component('ElIcon' + key, component)
  }
}

export default {install}
