Blue Triangle Help Center
Auto Light Dark
Auto Light Dark

What are the pros and cons of loading the BT tag before versus after onload?

 

 

Loading the tag before onload

Loading the tag after onload

Pros

  • more accurate data collection

  • able to set event listeners early on in the page to better collect CWV data

  • does not factor into onload time

Cons

  • factors into onload time

  • less accurate data collection for CWV

  • because event listeners occur late in the page load cycle. we could potentially miss INP, CLS, or LCP