[forgive] Don't look up user babel configs (#33010)

Projects with existing babel config files may confuse the LSP, so
explictly opt out of looking them up.
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/33010).
* #33012
* #33011
* __->__ #33010
This commit is contained in:
lauren 2025-04-24 13:29:56 -04:00 committed by GitHub
parent 197d6a0403
commit b06bb35ce9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -33,6 +33,8 @@ export async function compile({
plugins: ['typescript', 'jsx'], plugins: ['typescript', 'jsx'],
}, },
sourceType: 'module', sourceType: 'module',
configFile: false,
babelrc: false,
}); });
if (ast == null) { if (ast == null) {
return null; return null;
@ -48,6 +50,8 @@ export async function compile({
plugins, plugins,
sourceType: 'module', sourceType: 'module',
sourceFileName: file, sourceFileName: file,
configFile: false,
babelrc: false,
}); });
if (result?.code == null) { if (result?.code == null) {
throw new Error( throw new Error(