Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(babel-preset-app): pass full config to @babel/preset-env #5522

Merged
merged 1 commit into from May 29, 2020

Commits on May 25, 2020

  1. feat(babel-preset-app): pass full config to @babel/preset-env

    Pass not just the useBuiltIns and corejs options, but the whole
    envOptions object, into the @babel/preset-env preset that is used to
    transform @babel/runtime, just like for the @babel/preset-env that is
    used for the application source code. This allows users to also specify
    other options, such as `exclude` and `polyfills`, and have them apply
    here too.
    
    In particular, this can be used to exclude the Promise polyfill, e. g.
    if Promise is already polyfilled in some other way. Previously,
    
        exclude: ['es.promise'],
        polyfills: ['es.array.iterator', 'es.object.assign'],
    
    could be used to configure the preset for the application source code,
    but the babel runtime would be transformed without those options, and so
    es.promise would still end up being included.
    
    Closes vuejs#5208
    lucaswerkmeister committed May 25, 2020
    Copy the full SHA
    bfb4f18 View commit details
    Browse the repository at this point in the history