mirror of
https://github.com/zebrajr/react.git
synced 2025-12-06 12:20:20 +01:00
[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:
parent
197d6a0403
commit
b06bb35ce9
|
|
@ -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(
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user