Skip to main content
InterviewHubPRO
Section Overview
Q23

Question 23 of 50

Part 2: Core Architecture & Implementation (Mid-Level)

46%
Web Vitals & Performance (50 Qs)•Part 2: Core Architecture & Implementation (Mid-Level)

Reducing Total Blocking Time (TBT) with Dynamic Imports.

senior LevelCode ExampleSystem Design

In Simple Words:

  • Total Blocking Time (TBT): The lab proxy for INP. Measures total time between FCP and Time to Interactive (TTI) where tasks exceeded 50ms.
  • Dynamic Imports:
    javascript
    // Don't import heavy chart at initial load
    button.addEventListener('click', async () => {
      const { renderChart } = await import('./HeavyChart.js');
      renderChart();
    });
    
    Splits monolithic bundles into on-demand chunks, keeping the main thread clear during initial load.