0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Unknown custom element: <TagName> - did you register the component correctly?

Last updated at Posted at 2020-04-26

上記のエラー、いくつか原因があるそうです。以下の記事で気づくことができました。助かりました。

自分の場合、循環参照で問題が起こっていました。解決策は、以下のように非同期 import (asynchronous import) させることでです。

// 誤
import Component from './Component.vue'
export default {
  components: {
    Component
  },
}
// 正
export default {
  components: {
    Component: () => import('./Component.vue')
  },
}

他にも require を使う方法も記載されていました。以下、公式ドキュメントになります。


自分の場合はさらに Content と言うコンポーネント名を使おうとしていました。これが content と言う非推奨になっているタグとバッティングしていたらしく、さきに非推奨の content が適用されてさらによくわからない状態になっていました... orz

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?