This overview helps you quickly build a mental model and understand common workflows for performance monitoring. It explains how the Performance API and Timing Flag work together to create a closed loop from marking to analysis: Mark → Collect → Report → Analyze.
The goal of monitoring is to ensure that critical moments in your page's lifecycle can be accurately recorded, reported, and analyzed, allowing you to quickly trace issues back to the source code or specific UI locations. Centered around the Lynx rendering pipeline and standardized events, we recommend the following closed-loop workflow:
__lynx_timing_flag) on critical UI nodes or key data updates to define the rendering pipelines you need to monitor. The special flag __lynx_timing_actual_fmp can additionally generate the ActualFMP metric. For details, see Marking Rendering Pipelines.PerformanceObserver as early as possible on the front end (e.g., to listen for metric.fcp, pipeline, etc.), or consume events via asynchronous callbacks on the client side. For details, see Collecting Performance Events.PipelineEntry.identifier (the Timing Flag) and event timelines to trace problems back to the corresponding modules or data flows for debugging and review.Recommended minimum set of tracking points (for a basic production setup):
fcp (required), actual_fmp (when you need to measure the "first meaningful data paint")loadBundle (for the initial screen rendering), and the pipelines associated with your critical Timing Flags.init, metric, pipeline, and resource.PerformanceEntry objects are generated by the Lynx Engine. The front end subscribes to them via PerformanceObserver.observe([...]), and the client receives them through the onPerformanceEvent(entry) callback on an asynchronous thread.PipelineEntry and can also trigger a MetricActualFmpEntry.__lynx_timing_flag attribute on a UI element.__lynx_timing_actual_fmp additionally generates an ActualFMP metric event.<inline text/>, <block/>, and <template/>.PipelineEntry/ActualFMP → Combine with LoadBundleEntry/FCP to establish a baseline for initial rendering and updates → Report → Filter high-latency samples by different dimensions → Trace back to the component/data flow corresponding to the mark to identify the cause.PipelineEntry → Combine with the page's loadBundle event to create an end-to-end performance profile → Optimize the resource loading and layout stages separately.