@oazmi/superbuild-plugins - v0.1.0
    Preparing search index...

    Type Alias ReplaceContentFn

    ReplaceContentFn: (
        args: ReplaceContentFnArgs,
        ctx: ReplaceContentFnContext,
    ) => MaybePromise<void | undefined | EsbuildWarningsAndErrors>

    describes a function that takes in an html node and then updates its referenced contents with the new output_path.

    for instance, if you are updating the content of your <script src="..."></script> elements, your content replacement function will simply look like:

    const replaceScriptContent: ReplaceContentFn = (args, ctx) => {
    const
    new_output_path = args.outputPath,
    node = args.htmlNode
    htmlNode.attributes.src = new_output_path
    }

    TODO: the replace content function should return esbuild-compatible warnings and errors.

    Type Declaration