DevTools tells Babel to parse the source code using "jsx" and "typescript" plug-ins:
https://github.com/facebook/react/blob/ed6c091fe961a3b95e956ebcefe8f152177b1fb7/packages/react-devtools-extensions/src/parseHookNames.js#L446-L462

This will work for some simple usages of Flow, but syntax may diverge and cause the parsing to fail.

Let's scan the source code for a `@flow` pragma and pass "flow" instead of "typescript" if one is found.

---

We should also add tests for both Flow and TypeScript to the test component pool:
https://github.com/facebook/react/tree/main/packages/react-devtools-extensions/src/__tests__/__source__
source === 'Inline Babel script' ||
              runtimeSourceURL.endsWith(source),
          );
          if (match) {
            setPromises.push(
              new SourceMapConsumer(parsed).then(sourceConsumer => {
                hookSourceData.sourceConsumer = sourceConsumer;
              }),
            );
            break;
          }
        } else {
          if (sourceMappingURLs.length > 1) {
            console.warn(
              'More than one external source map detected in the source file',
            );
          }
          let url = sourceMappingURLs[i].split('=')[1];
          if (!url.startsWith('http') && !url.startsWith('/')) {
            
            const lastSlashIdx = runtimeSourceURL.lastIndexOf('/');
            if (lastSlashIdx !== -1) {
              const baseURL = runtimeSourceURL.slice(
                0,
                runtimeSourceURL.lastIndexOf('/'),
              );
              url = `${baseURL}/${url}`;
            }
          }
          hookSourceData.sourceMapURL = url;