Hi,
First of all, thank you for maintaining core-js, it’s an incredibly valuable project.
I’m opening this issue to ask for guidance regarding the current shift in the frontend ecosystem away from Babel/SWC toward newer toolchains like OXC (now used in Vite 8).
Context
Historically, core-js has been commonly used together with Babel:
@babel/preset-env
useBuiltIns: 'usage' | 'entry'
- automatic polyfill injection based on targets
This provided a very convenient and mostly automatic experience.
Current situation
With Vite 8 using OXC, the situation is different:
- OXC focuses on syntax transforms
- It does not provide automatic polyfill injection
- There is no direct equivalent to Babel’s
useBuiltIns: 'usage'
As a result, we now need to:
- manually import
core-js, or
- rely on external plugins (e.g. legacy plugins), or
- use external polyfill services
Questions
-
Does core-js have a recommended approach for usage in environments without Babel/SWC?
-
Is there any official or recommended integration strategy for:
- Vite 8 (OXC)
- or similar “no-Babel” toolchains?
-
Are there any plans (or discussions) around:
a plugin/tool that can replicate useBuiltIns: 'usage' behavior outside Babel?
-
Would the recommended approach today be:
- importing
core-js/actual manually, or
- using something like
@vitejs/plugin-legacy?
Motivation
It would be helpful to have clear best practices or an officially recommended ecosystem approach so that developers don’t accidentally over-polyfill or miss required features.
Thanks again for your work 🙏
Hi,
First of all, thank you for maintaining core-js, it’s an incredibly valuable project.
I’m opening this issue to ask for guidance regarding the current shift in the frontend ecosystem away from Babel/SWC toward newer toolchains like OXC (now used in Vite 8).
Context
Historically,
core-jshas been commonly used together with Babel:@babel/preset-envuseBuiltIns: 'usage' | 'entry'This provided a very convenient and mostly automatic experience.
Current situation
With Vite 8 using OXC, the situation is different:
useBuiltIns: 'usage'As a result, we now need to:
core-js, orQuestions
Does
core-jshave a recommended approach for usage in environments without Babel/SWC?Is there any official or recommended integration strategy for:
Are there any plans (or discussions) around:
a plugin/tool that can replicate
useBuiltIns: 'usage'behavior outside Babel?Would the recommended approach today be:
core-js/actualmanually, or@vitejs/plugin-legacy?Motivation
It would be helpful to have clear best practices or an officially recommended ecosystem approach so that developers don’t accidentally over-polyfill or miss required features.
Thanks again for your work 🙏