[Vuejs]-Failed to define Vue single file component (CLI) in Loop, like app->A->B->A->B

0👍

I have figured this out myself:
https://v2.vuejs.org/v2/guide/components-edge-cases.html#Recursive-Components

it should be:

beforeCreate() {
    this.$options.components.ComponentA = require("./ComponentA").default;
},

Leave a comment