A virtual module definition.
Type:
stringThe context for the virtual module. A string path. Defaults to 'auto', which will try to resolve the context from the module id.
virtualModule.source(loaderContext): string | Buffer<ArrayBufferLike> | Promise<string | Buffer<ArrayBufferLike>>
Attributes
loaderContext:
LoaderContext<any>The source function that provides the virtual content.
Type:
stringThe module type.
Optional version function or value for cache invalidation.