Skip to content

Commit

Permalink
import correct babel register (#46987)
Browse files Browse the repository at this point in the history
Summary:

X-link: facebook/metro#1371

Update `babel/register` to latest version, fixing the bug that were preventing us from updating it previously.

Differential Revision: D64245277
  • Loading branch information
vzaidman authored and facebook-github-bot committed Oct 11, 2024
1 parent c86b5c1 commit d9e6c78
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion scripts/build/babel-register.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,11 @@ function registerForMonorepo() {
return;
}

require('metro-babel-register')([PACKAGES_DIR]);
if (process.env.FBSOURCE_ENV === '1') {
require('@fb-tools/babel-register');
} else {
require('metro-babel-register')([PACKAGES_DIR]);
}

isRegisteredForMonorepo = true;
}
Expand Down

0 comments on commit d9e6c78

Please sign in to comment.