ComponentLoader
type ComponentLoader<T> = () => T | Promise<T>;Provides a component when invoked. Return import("./X").then(m => m.X) to split it into its own
chunk, or the eagerly-imported component (sync) to keep it in the entry bundle — the caller decides.
Type Parameters
Section titled “Type Parameters”T
Returns
Section titled “Returns”T | Promise<T>