2

We're using babel-preset-env and a specified set of browser versions as targets so that only the needed transforms are applied. We would like to keep this set of versions inline with the versions that are supported by the vendors while staying as permissive as possible in that support. So is there a way to list the transforms that are applied for a set of targets. For example, if you did the following (like the example):

const presets = [
  [
    "@babel/env",
    {
      targets: {
        edge: "17",
        firefox: "60",
        chrome: "67",
        safari: "11.1",
      },
      useBuiltIns: "usage",
    },
  ],
];

Then how can we tell the set of transforms that will be applied with that setup? We want to know this because Firefox ESR was recently updated to 68 and it would be nice to check if updating that would change anything about the transforms that are applied. Also, would updating the Safari version to 12 change anything? Because if not, then it may be worth just sticking with the older version number to support more users since it won't really change anything in our build output.

So is there a way to get the list of transformations for a specific set of targets to understand how it will impact our build output?

Dilshod K
  • 2,924
  • 1
  • 13
  • 46
Dave Johansen
  • 889
  • 1
  • 7
  • 23
  • I would like to know too. The default for `preset-env` includes Firefox ESR, and I'd like to know what I'm actually transpiling to. And how bad is supporting Firefox ESR compared to IE 11? (I suppose ESR is much better than IE 11, but it would still be nice to know more easily). – trusktr Apr 25 '20 at 02:46

0 Answers0