Skip to content

installing @babel/node@7.5.5 also install @babel/polyfill as dependency  #10295

@ApolloTang

Description

@ApolloTang

Bug Report

Current Behavior

$ yarn init -y
yarn init v1.16.0
warning The yes flag has been set. This will automatically answer yes to all questions, which may have security implications.
success Saved package.json
✨  Done in 0.02s.
~/Desktop/test-babel-node
$ yarn add @babel/node
yarn add v1.16.0
info No lockfile found.
[1/4] 🔍  Resolving packages...
warning @babel/node > @babel/polyfill@7.4.4: 🚨 As of Babel 7.4.0, this
package has been deprecated in favor of directly
including core-js/stable (to polyfill ECMAScript
features) and regenerator-runtime/runtime
(needed to use transpiled generator functions):

  > import "core-js/stable";
  > import "regenerator-runtime/runtime";
[2/4] 🚚  Fetching packages...
[3/4] 🔗  Linking dependencies...
warning "@babel/node > @babel/register@7.5.5" has unmet peer dependency "@babel/core@^7.0.0-0".
warning " > @babel/node@7.5.5" has unmet peer dependency "@babel/core@^7.0.0-0".
[4/4] 🔨  Building fresh packages...
success Saved lockfile.
success Saved 38 new dependencies.
info Direct dependencies
└─ @babel/node@7.5.5
info All dependencies
├─ @babel/node@7.5.5
├─ @babel/polyfill@7.4.4
├─ @babel/register@7.5.5

+++ output not shown +++

├─ core-js@2.6.9

+++ output not shown +++

├─ regenerator-runtime@0.13.3
├─ semver@5.7.0
├─ source-map-support@0.5.13
├─ source-map@0.6.1
└─ v8flags@3.1.3
✨  Done in 3.23s.

Expected behavior/code

Since we have migrated to core-js@3, we should not have the following dependencies installed by default:

  • @babel/polyfill
  • core-js@2
  • regenerator-runtime

Environment

  • Babel version(s): [@babel/node@7.5.5]

Metadata

Metadata

Assignees

No one assigned

    Labels

    outdatedA closed issue/PR that is archived due to age. Recommended to make a new issue

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions