This example shows different strategies that can be used for the next/script
component:
Preview the example live on StackBlitz:
Deploy the example using Vercel:
Execute create-next-app
with npm or Yarn to bootstrap the example:
npx create-next-app --example script-component script-component-app
# or
yarn create next-app --example script-component script-component-app
Deploy it to the cloud with Vercel (Documentation).