Use optional chaining where possible (#13773)
This commit is contained in:
1 parent
6c688b7e28
commit
59eda43d71
46 files changed
+126
-233
No files matched your search
@@ -66,7 +66,7 @@ const appendPlugins = (plugins, options = parseOptions) => ({
|
||||
// https://github.com/babel/babel/pull/7934/files#diff-a739835084910b0ee3ea649df5a4d223R67
|
||||
const FLOW_PRAGMA_REGEX = /@(?:no)?flow\b/;
|
||||
function isFlowFile(text, options) {
|
||||
if (options.filepath && options.filepath.endsWith(".js.flow")) {
|
||||
if (options.filepath?.endsWith(".js.flow")) {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user