最近,在开发中用到了空状态组件el-empty,调试时发现空状态时的占位并没有显示出来,并在控制台中报错如下:
[Vue warn]: Unknown custom element: <el-empty> - did you register the component correctly? For recursive components, make sure to provide the "name" option.
解决办法:项目中已经全局引用了element,经查询发现是现有的element的版本太旧,重新安装升级element,查询官方获取目前最新版本为2.15.7,更新后解决了上述问题。