Add Scheduling Profiler GK link to Timeline UI for FB build (#22730)
This is a constant source of confusion for FB engineers trying to figure out why Chrome profiling data does not have any React marks.
Brian Vaughn committed
Nov 9, 2021 at 16:10 UTC
e0aa5e205feee53043ce1ae8726fe732866e6ea7
1 file changed
+14
packages/react-devtools-timeline/src/Timeline.js
+14
@@ -10,6 +10,7 @@
10
import type {DataResource} from './createDataResourceFromImportedFile';
11
import type {ViewState} from './types';
12
13
+import {isInternalFacebookBuild} from 'react-devtools-feature-flags';
14
import * as React from 'react';
15
import {
16
Suspense,
@@ -79,6 +80,19 @@ export function Timeline(_: {||}) {
80
81
const Welcome = ({onFileSelect}: {|onFileSelect: (file: File) => void|}) => (
82
<ol className={styles.WelcomeInstructionsList}>
83
+ {isInternalFacebookBuild && (
84
+ <li className={styles.WelcomeInstructionsListItem}>
85
+ Enable the
86
+ <a
87
+ className={styles.WelcomeInstructionsListItemLink}
88
+ href="https://fburl.com/react-devtools-scheduling-profiler-gk"
89
+ rel="noopener noreferrer"
90
+ target="_blank">
91
+ <code>react_enable_scheduling_profiler</code> GK
92
+ </a>
93
+ .
94
+ </li>
95
+ )}
96
<li className={styles.WelcomeInstructionsListItem}>
97
Open a website that's built with the
98
<a