worker strategy

An experimental next/script strategy that runs a third-party script in a web worker using Partytown, keeping it off the main thread.

In more detail

It needs the nextScriptWorkers flag. As of Next.js 15 it does not work with the App Router, so treat it as a Pages Router option.

Related terms

Taught in

References