From 8646349aebb514eeef7e01614fb4aeb2f2c7a6c8 Mon Sep 17 00:00:00 2001 From: lauren Date: Wed, 12 Mar 2025 19:12:33 -0400 Subject: [PATCH] [rollup] Fix codeFrame is not a function (#32591) Extracting portions of #32416 for easier review. Fixes a small issue where `codeFrame` is not a function when a rollup error was encountered. Co-authored-by: michael faith --- [//]: # (BEGIN SAPLING FOOTER) Stack created with [Sapling](https://sapling-scm.com). Best reviewed with [ReviewStack](https://reviewstack.dev/facebook/react/pull/32591). * #32592 * __->__ #32591 * #32590 * #32589 * #32588 --------- Co-authored-by: michael faith --- scripts/rollup/build.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/rollup/build.js b/scripts/rollup/build.js index 874b5b139f..71bfb1c338 100644 --- a/scripts/rollup/build.js +++ b/scripts/rollup/build.js @@ -22,7 +22,7 @@ const useForks = require('./plugins/use-forks-plugin'); const dynamicImports = require('./plugins/dynamic-imports'); const Packaging = require('./packaging'); const {asyncRimRaf} = require('./utils'); -const codeFrame = require('@babel/code-frame'); +const codeFrame = require('@babel/code-frame').default; const Wrappers = require('./wrappers'); const RELEASE_CHANNEL = process.env.RELEASE_CHANNEL;