Nuxt 2.11.0 では core-js@3.X がサポートされていないらしい

ポートフォリオサイトの Nuxt プロジェクトに firebase を導入したところ、core-js のモジュールが不足しているとのエラーが出ていたので、最新バージョンの core-js をインストールしたところ、再びエラーが発生してハマった。

 ERROR  Failed to compile with 39 errors                                                    friendly-errors 01:13:23

These dependencies were not found:                                                          friendly-errors 01:13:23
                                                                                            friendly-errors 01:13:23
* core-js/modules/es6.array.find in ./.nuxt/client.js                                       friendly-errors 01:13:23
* core-js/modules/es6.array.iterator in ./.nuxt/client.js, ./plugins/firebase.js            friendly-errors 01:13:23
* core-js/modules/es6.date.to-string in ./.nuxt/utils.js, ./.nuxt/components/nuxt.js        friendly-errors 01:13:23
* core-js/modules/es6.function.name in ./.nuxt/client.js, ./node_modules/babel-loader/lib??ref--2-0!./node_modules/vue-loader/lib??vue-loader-options!./components/SkillList.vue?vue&type=script&lang=js&
* core-js/modules/es6.object.assign in ./.nuxt/client.js, ./plugins/firebase.js             friendly-errors 01:13:23
* core-js/modules/es6.object.keys in ./.nuxt/client.js                                      friendly-errors 01:13:23
* core-js/modules/es6.object.to-string in ./.nuxt/client.js, ./.nuxt/components/nuxt-link.client.js
* core-js/modules/es6.promise in ./.nuxt/client.js, ./plugins/firebase.js                   friendly-errors 01:13:23
* core-js/modules/es6.regexp.constructor in ./.nuxt/utils.js                                friendly-errors 01:13:23
* core-js/modules/es6.regexp.match in ./.nuxt/client.js                                     friendly-errors 01:13:23
* core-js/modules/es6.regexp.replace in ./.nuxt/utils.js, ./.nuxt/components/nuxt.js        friendly-errors 01:13:23
* core-js/modules/es6.regexp.search in ./.nuxt/utils.js                                     friendly-errors 01:13:23
* core-js/modules/es6.regexp.split in ./.nuxt/utils.js, ./node_modules/babel-loader/lib??ref--2-0!./node_modules/vue-loader/lib??vue-loader-options!./.nuxt/components/nuxt-build-indicator.vue?vue&type=script&lang=js&
* core-js/modules/es6.regexp.to-string in ./.nuxt/utils.js, ./.nuxt/components/nuxt.js      friendly-errors 01:13:23
* core-js/modules/es6.string.includes in ./.nuxt/client.js, ./.nuxt/components/nuxt-link.client.js
* core-js/modules/es6.string.iterator in ./.nuxt/client.js                                  friendly-errors 01:13:23
* core-js/modules/es6.string.repeat in ./.nuxt/utils.js                                     friendly-errors 01:13:23
* core-js/modules/es6.string.starts-with in ./.nuxt/utils.js                                friendly-errors 01:13:23
* core-js/modules/es6.symbol in ./.nuxt/client.js, ./.nuxt/components/nuxt-link.client.js   friendly-errors 01:13:23
* core-js/modules/es7.array.includes in ./.nuxt/client.js, ./.nuxt/components/nuxt-link.client.js
* core-js/modules/es7.object.get-own-property-descriptors in ./.nuxt/index.js               friendly-errors 01:13:23
* core-js/modules/es7.promise.finally in ./.nuxt/client.js, ./plugins/firebase.js           friendly-errors 01:13:23
* core-js/modules/es7.symbol.async-iterator in ./.nuxt/client.js, ./.nuxt/components/nuxt-link.client.js
* core-js/modules/web.dom.iterable in ./.nuxt/client.js, ./.nuxt/components/nuxt-link.client.js
                                                                                            friendly-errors 01:13:23
To install them, you can run: npm install --save core-js/modules/es6.array.find core-js/modules/es6.array.iterator core-js/modules/es6.date.to-string core-js/modules/es6.function.name core-js/modules/es6.object.assign core-js/modules/es6.object.keys core-js/modules/es6.object.to-string core-js/modules/es6.promise core-js/modules/es6.regexp.constructor core-js/modules/es6.regexp.match core-js/modules/es6.regexp.replace core-js/modules/es6.regexp.search core-js/modules/es6.regexp.split core-js/modules/es6.regexp.to-string core-js/modules/es6.string.includes core-js/modules/es6.string.iterator core-js/modules/es6.string.repeat core-js/modules/es6.string.starts-with core-js/modules/es6.symbol core-js/modules/es7.array.includes core-js/modules/es7.object.get-own-property-descriptors core-js/modules/es7.promise.finally core-js/modules/es7.symbol.async-iterator core-js/modules/web.dom.iterable

Issue でもいくつか同様の事象が起票されていることが分かり、どうやら core-js 3系のサポートがまだ未完了とのことだった。

core-js 2系をインストールしたところ、無事アプリケーションが動くようになった。

また、以下の PR で、core-js 3系へのサポートを行っているとのこと。

github.com