Closed lili2311 closed 3 years ago
babel 5 was never supported by 5.x
. In a couple of initial versions it wasn't completely broken but it always used babel 7 internally. 5.2.0 added a direct error if you attempt to load this plugin into babel 5, that was a bug fix. If you are using babel 5 then babel-plugin-istanbul 4.x is the latest version which supports this.
The structure of this module is not great, it actually does pull @babel/core
7.x as a production dependency via istanbul-lib-instrument but we cannot control what you run it under (beyond throwing an error as we do). I am looking to improve the structure for babel-plugin-istanbul@7.0.0
but nothing can be done without another semver-major release.
👋 When upgrading locally a version of
babel-plugin-istanbul
to5.2.0
a new version of babel-core is not brought in (as it is listed as a dev dependency) but the app tests are not possible to run as it will not compile.What is the expectation that users know to upgrade these two together? Would it make sense to move babel-core to be a production dependency so the upgrades correctly pull in the right version of the babel-core their require to work? What are your thoughts & suggestions on this please?
https://github.com/istanbuljs/babel-plugin-istanbul/blob/master/package.json#L20