فهرست منبع

warn async component in v-repeat + dynamic

Evan You 11 سال پیش
والد
کامیت
64643b6cf6
1فایلهای تغییر یافته به همراه6 افزوده شده و 0 حذف شده
  1. 6 0
      src/directives/repeat.js

+ 6 - 0
src/directives/repeat.js

@@ -176,6 +176,12 @@ module.exports = {
     var id = this.ctorGetter.call(context, context)
     var Ctor = this.vm.$options.components[id]
     _.assertAsset(Ctor, 'component', id)
+    if (!Ctor.options) {
+      _.warn(
+        'Async resolution is not supported for v-repeat ' +
+        '+ dynamic component. (component: ' + id + ')'
+      )
+    }
     return Ctor
   },