In one of my ReactJS applications I encountered an error during build with a Yarn/Babel setup:
Babel 7 - ReferenceError: regeneratorRuntime is not defined.
If you are using Babel 7.4.0 or newer, then
@babel/polyfill has been deprecated. Instead, you need to use
regenerator-runtime/runtime. These can be added with Yarn:
yarn add core-js yarn add regenerator-runtime
import 'core-js/stable' import 'regenerator-runtime/runtime'