From 9b434a5ab1eeb12ca7743ac803e03ce8aadbc6b9 Mon Sep 17 00:00:00 2001 From: Damian Senn Date: Tue, 24 Sep 2019 09:19:14 +0200 Subject: [PATCH 1/2] Add runtime version to transform-runtime plugin --- packages/babel-preset-react-app/create.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/babel-preset-react-app/create.js b/packages/babel-preset-react-app/create.js index 7b7f1da6ed1..f92f5d931cf 100644 --- a/packages/babel-preset-react-app/create.js +++ b/packages/babel-preset-react-app/create.js @@ -170,6 +170,10 @@ module.exports = function(api, opts, env) { { corejs: false, helpers: areHelpersEnabled, + // By default, babel assumes babel/runtime version 7.0.0-beta.0, + // explicitely resolving to match the provided helper functions. + // https://github.com/babel/babel/issues/10261 + version: require('@babel/runtime/package.json').version, regenerator: true, // https://babeljs.io/docs/en/babel-plugin-transform-runtime#useesmodules // We should turn this on once the lowest version of Node LTS From 35bab6766e1a39769bcbd717e8e48c1ed32ae922 Mon Sep 17 00:00:00 2001 From: Ian Schmitz Date: Sat, 5 Oct 2019 15:38:54 -0700 Subject: [PATCH 2/2] Update create.js --- packages/babel-preset-react-app/create.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/babel-preset-react-app/create.js b/packages/babel-preset-react-app/create.js index f92f5d931cf..88e345db082 100644 --- a/packages/babel-preset-react-app/create.js +++ b/packages/babel-preset-react-app/create.js @@ -171,7 +171,7 @@ module.exports = function(api, opts, env) { corejs: false, helpers: areHelpersEnabled, // By default, babel assumes babel/runtime version 7.0.0-beta.0, - // explicitely resolving to match the provided helper functions. + // explicitly resolving to match the provided helper functions. // https://github.com/babel/babel/issues/10261 version: require('@babel/runtime/package.json').version, regenerator: true,