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 3 years have passed since last update.

IE11でNuxt.jsを使用した際に「strict モードでは、プロパティの複数定義は許可されません。」とでたときの対応メモ

Last updated at Posted at 2021-04-23

strictモードをやめれば解決しますが、その前に確認しておきたい点として componentを明示的にimportしているか という箇所になります。

nuxt.js はテンプレート部に直接 /components ディレクトリ配下のファイルを、importせずにファイル名をタグとして使用できる。
しかしどうもそれを多様しているとIE11で表題のエラーになる場合がある。

<HeaderMenu></HeaderMenu>

みたいな感じで components/HeaderMenu.vue を呼び出している場合は以下に修正するとよさそう。

page.vue
import HeaderMenu from "@/components/HeaderMenu";
export default {
  components: {
    HeaderMenu,
  }
}

<template>
  <header-menu></header-menu>
</template>

内部コードを読むところまではしなかったけど、わたしの場合はこれで直りました。
あなたの場合はどうでしょう。ごきげんよう

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?