-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
nuxt/babel-preset-app incorrectly depends on core-js@2.x.x #9851
Copy link
Copy link
Closed
Labels
Description
Trying to remove core-js 2.x instances from my build - seems that @nuxt/babel-preset-app depends on a 2.x version.
looking into your readme, https://www.npmjs.com/package/@nuxt/babel-preset-app , added the "@babel/runtime-corejs3": "^7.15.4",, also specified corejs 3 in the babel.config.js file :
// This file is required for running the tests
module.exports = {
presets: [
[
'@babel/preset-env',
{
useBuiltIns: 'usage',
corejs: { version: 3 },
},
],
],
}Here's the yarn why core-js output:
> yarn why core-js
yarn why v1.22.11
[1/4] 🤔 Why do we have the module "core-js"...?
[2/4] 🚚 Initialising dependency graph...
[3/4] 🔍 Finding dependency...
[4/4] 🚡 Calculating file sizes...
=> Found "core-js@3.18.0"
info Has been hoisted to "core-js"
info Reasons this module exists
- Specified in "devDependencies"
- Hoisted from "dd-trace#core-js"
info Disk size without dependencies: "7.86MB"
info Disk size with unique dependencies: "7.86MB"
info Disk size with transitive dependencies: "7.86MB"
info Number of shared dependencies: 0
=> Found "@nuxt/babel-preset-app#core-js@2.6.12"
info This module exists because "nuxt#@nuxt#babel-preset-app" depends on it.
info Disk size without dependencies: "7.68MB"
info Disk size with unique dependencies: "7.68MB"
info Disk size with transitive dependencies: "7.68MB"
info Number of shared dependencies: 0
=> Found "babel-runtime#core-js@2.6.12"
info This module exists because "jest-vue-preprocessor#babel-plugin-transform-runtime#babel-runtime" depends on it.
info Disk size without dependencies: "7.68MB"
info Disk size with unique dependencies: "7.68MB"
info Disk size with transitive dependencies: "7.68MB"
info Number of shared dependencies: 0
✨ Done in 1.01s.
{
"name": "profile-page",
"version": "",
"description": "",
"author": "",
"private": true,
"scripts": {
"dev": "nuxt",
"dev:debug": "DEBUG=nuxt:* node --inspect node_modules/.bin/nuxt",
"build": "nuxt build --modern=client",
"build:analyze": "nuxt build -a",
"start": "nuxt start --modern=client",
"generate": "nuxt generate",
},
"dependencies": {
"@koumoul/nuxt-config-inject": "^0.4.10",
"@nuxtjs/axios": "^5.13.6",
"@nuxtjs/device": "^2.1.0",
"@nuxtjs/proxy": "^2.1.0",
"@nuxtjs/robots": "^2.5.0",
"@nuxtjs/router": "^1.6.1",
"@nuxtjs/sentry": "~5.1.3",
"@nuxtjs/style-resources": "^1.2.0",
"@nuxtjs/stylelint-module": "^4.0.0",
"@nuxtjs/svg": "~0.2.0",
"@visable/ab-testing": "^3.1.0",
"@visable/favourites": "^1.5.0",
"@visable/routing": "^2.9.0",
"@visable/tracking": "^1.10.1",
"@visable/vue": "^4.1.1",
"@wlw/styleguide": "^32.18.0",
"array-from": "^2.1.1",
"await-to-js": "^3.0.0",
"consola": "^2.15.3",
"cookie-universal-nuxt": "^2.1.5",
"css-loader": "^5.2.7",
"dd-trace": "^0.31.4",
"imgix.js": "^3.5.1",
"insane": "^2.6.2",
"json2csv": "^5.0.5",
"lazysizes": "^5.3.2",
"lodash.omit": "^4.5.0",
"node-sass": "^5.0.0",
"nuxt": "^2.15.7",
"nuxt-breakpoints": "^1.1.9",
"picturefill": "^3.0.3",
"portal-vue": "^2.1.7",
"sass-loader": "^10.1.1",
"v-tooltip": "2.1.3",
"vee-validate": "~3.4.13",
"vue-clipboard2": "~0.3.3",
"vue-date-pick": "^1.4.1",
"vue-i18n": "~8.25.1",
"vue-lazy-hydration": "^2.0.0-beta.4",
"vue-observe-visibility": "^1.0.0",
"vue-popperjs": "^2.3.0",
"vue-slick-carousel": "^1.0.6",
"vuejs-paginate": "^2.1.0",
"weighted-random": "^0.1.0"
},
"devDependencies": {
"@babel/core": "~7.15.5",
"@babel/preset-env": "~7.15.6",
"@babel/runtime-corejs3": "^7.15.4",
"@cypress/vue": "^2.2.3",
"@nuxt/image": "~0.6.0",
"@vue/cli-plugin-eslint": "^4.5.13",
"@vue/cli-service": "^4.5.13",
"@vue/eslint-config-airbnb": "^5.3.0",
"@vue/test-utils": "^1.2.2",
"babel-core": "^7.0.0-bridge.0",
"babel-eslint": "^10.1.0",
"babel-jest": "^26.6.3",
"commitizen": "^4.2.4",
"core-js": "3",
"cypress": "~8.4.1",
"cz-conventional-changelog": "3.3.0",
"eslint": "^7.32.0",
"eslint-config-prettier": "^8.3.0",
"eslint-loader": "^4.0.2",
"eslint-plugin-cypress": "~2.12.1",
"eslint-plugin-html": "~6.2.0",
"eslint-plugin-import": "~2.24.2",
"eslint-plugin-prettier": "~4.0.0",
"eslint-plugin-vue": "~7.18.0",
"git-branch-is": "^4.0.0",
"husky": "^4.3.8",
"jest": "^26.6.3",
"jest-serializer-vue": "^2.0.2",
"jest-transform-stub": "^2.0.0",
"jest-vue-preprocessor": "^1.7.1",
"jsdom": "^16.7.0",
"lint-staged": "~11.1.2",
"prettier": "~2.4.1",
"stylelint": "^13.13.1",
"stylelint-config-prettier": "^8.0.2",
"stylelint-scss": "~3.21.0",
"vue-jest": "^3.0.7",
"vuex-mock-store": "^0.0.8"
},
"husky": {
"hooks": {
"pre-commit": "lint-staged",
"post-merge": "git-branch-is master && yarn install"
}
},
"lint-staged": {
"*.js": "yarn lint:js",
"*.vue": "yarn lint:css"
},
"browserslist": [
"> 1%",
"last 2 versions",
"not IE 11",
"not dead"
],
"config": {
"commitizen": {
"path": "./node_modules/cz-conventional-changelog",
"maxHeaderWidth": 150,
"maxLineWidth": 150
}
}
}Reactions are currently unavailable