Skip to content

Conversation

@nicolo-ribaudo
Copy link
Member

@nicolo-ribaudo nicolo-ribaudo commented Jul 21, 2023

Q                       A
Fixed Issues?
Patch: Bug Fix?
Major: Breaking Change?
Minor: New Feature?
Tests Added + Pass? Yes
Documentation PR Link babel/website#2817
Any Dependency Changes?
License MIT

All these packages won't be needed in Babel 8, and they have a peer dependency on Babel 7 which causes warnings.

shouldTransformESM: boolean;
shouldTransformDynamicImport: boolean;
shouldTransformExportNamespaceFrom: boolean;
shouldParseTopLevelAwait: boolean;
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TLA is now enabled by default in our parser, so we can unconditionally add the syntax plugin for older parser versions.

@babel-bot
Copy link
Collaborator

babel-bot commented Jul 21, 2023

Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/54928/

@nicolo-ribaudo
Copy link
Member Author

nicolo-ribaudo commented Jul 21, 2023

A fresh install of @babel/core and @babel/preset-env 8.0.0-alpha.0 currently has these unmet peer dependencies:

➤ YN0000: root-workspace-0b6124@workspace:. provides @babel/core@npm:8.0.0-alpha.0 [dc3fc] with version 8.0.0-alpha.0, which doesn't satisfy the following requirements:

➤ YN0000: @babel/helper-compilation-targets@npm:7.22.9 [35afd]                                                    → ^7.0.0                      ✘
➤ YN0000: @babel/helper-create-regexp-features-plugin@npm:7.22.9 [571ed]                                          → ^7.0.0                      ✘
➤ YN0000: @babel/plugin-proposal-unicode-property-regex@npm:7.18.6 [3afcd]                                        → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-async-generators@npm:7.8.4 [061ff]                                                 → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-class-properties@npm:7.12.13 [061ff]                                               → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-class-static-block@npm:7.14.5 [061ff]                                              → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-dynamic-import@npm:7.8.3 [061ff]                                                   → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-export-namespace-from@npm:7.8.3 [061ff]                                            → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-import-meta@npm:7.10.4 [061ff]                                                     → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-json-strings@npm:7.8.3 [061ff]                                                     → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-logical-assignment-operators@npm:7.10.4 [061ff]                                    → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-nullish-coalescing-operator@npm:7.8.3 [061ff]                                      → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-numeric-separator@npm:7.10.4 [061ff]                                               → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-object-rest-spread@npm:7.8.3 [061ff]                                               → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-optional-catch-binding@npm:7.8.3 [061ff]                                           → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-optional-chaining@npm:7.8.3 [061ff]                                                → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-private-property-in-object@npm:7.14.5 [061ff]                                      → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-top-level-await@npm:7.14.5 [061ff]                                                 → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-syntax-unicode-sets-regex@npm:7.18.6 [061ff]                                              → ^7.0.0                      ✘
➤ YN0000: @babel/plugin-transform-dotall-regex@npm:7.22.5 [3afcd]                                                 → ^7.0.0-0                    ✘

➤ YN0000: Note: these requirements start with @babel/preset-env@npm:8.0.0-alpha.0 [dc3fc]

Some of them are through @babel/preset-modules dependencies, but this PR already allows us to get rid of most of them:

A fresh install of @babel/core and @babel/preset-env 8.0.0-alpha.0 currently has these unmet peer dependencies:

➤ YN0000: root-workspace-0b6124@workspace:. provides @babel/core@npm:8.0.0-alpha.0 [dc3fc] with version 8.0.0-alpha.0, which doesn't satisfy the following requirements:

➤ YN0000: @babel/helper-compilation-targets@npm:7.22.9 [35afd]                                                    → ^7.0.0                      ✘
➤ YN0000: @babel/helper-create-regexp-features-plugin@npm:7.22.9 [571ed]                                          → ^7.0.0                      ✘
➤ YN0000: @babel/plugin-proposal-unicode-property-regex@npm:7.18.6 [3afcd]                                        → ^7.0.0-0                    ✘
➤ YN0000: @babel/plugin-transform-dotall-regex@npm:7.22.5 [3afcd]                                                 → ^7.0.0-0                    ✘

➤ YN0000: Note: these requirements start with @babel/preset-env@npm:8.0.0-alpha.0 [dc3fc]

Some of them are through @babel/preset-modules dependencies, but this PR already allows us to get rid of most of them.

@nicolo-ribaudo nicolo-ribaudo force-pushed the env-syntax-deps-babel-8 branch from 05ad8c3 to 304a9e4 Compare July 21, 2023 10:54
Copy link
Contributor

@JLHwung JLHwung left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: we should also remove them from the babel-standalone, maybe in another PR.

@nicolo-ribaudo nicolo-ribaudo merged commit 6b91b9b into babel:main Jul 24, 2023
@nicolo-ribaudo nicolo-ribaudo deleted the env-syntax-deps-babel-8 branch July 24, 2023 16:48
@JLHwung JLHwung added PR: Breaking Change 💥 A type of pull request used for our changelog categories for next major release and removed babel 8 labels Aug 9, 2023
@JLHwung JLHwung added this to the v8.0.0 milestone Aug 9, 2023
@github-actions github-actions bot added the outdated A closed issue/PR that is archived due to age. Recommended to make a new issue label Nov 24, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

outdated A closed issue/PR that is archived due to age. Recommended to make a new issue PR: Breaking Change 💥 A type of pull request used for our changelog categories for next major release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants