@bolttech/server-side-next
Version:
This library was generated with [Nx](https://nx.dev).
17 lines (16 loc) • 568 B
TypeScript
/// <reference types="react" />
import { NextScript } from 'next/document';
declare type DocumentFiles = {
sharedFiles: readonly string[];
pageFiles: readonly string[];
allFiles: readonly string[];
};
/**
* Custom NextScript to defer loading of unnecessary JS.
* Standard behavior is async. Compatible with Next.js 10.0.3
*/
declare class DeferredNextScript extends NextScript {
getDynamicChunks(files: DocumentFiles): (JSX.Element | null)[];
getScripts(files: DocumentFiles): JSX.Element[];
}
export default DeferredNextScript;