Put in order · Next.js course · Module 2: Routing and Layouts

Using the Script Component

Arrange the usage syntax of the Script component from Next.js

Items to put in order

  • import Script
  • <Script src="https://example.com/widget.js"
  • from 'next/script'
  • strategy="afterInteractive" />
Show the answer

Correct order:

  1. import Script
  2. from 'next/script'
  3. <Script src="https://example.com/widget.js"
  4. strategy="afterInteractive" />