Skip to content

[Enhancement] A Post Processor is required for WebPack to remove @DynamicProtoStub tagged methods #27

Open
@MSNev

Description

@MSNev

While a rollup plugin is available to remove the stub functions tagged with @DynamicProtoStub, we should really look at providing a version for WebPack.

As per the readme, tagged functions/methods should be removed from the resulting code as they are necessary to ensure that TypeScript provides the correct resulting definition (*.d.ts) where the functions are declared as "prototype" level functions.

/**
 * The typedoc comments
 */
// @DynamicProtoStub
public toBeRemoved():void {
}
 
// @DynamicProtoStub
public toBeRemoved():void {
}

/**
 * This function does stuff
 * @param args - used in the function
 */
public myFunction(args:string): void {
    ...
} // @DynamicProtoStub - Function will be removed

public myFunction2(): void {
...
}  // @DynamicProtoStub - Function will be removed

/**
 * This function does stuff
 * @param args - used in the function
 */
public myFunction(args:string): void {
    // @DynamicProtoStub - Function will be removed
}

public myFunction2(): void {
    /* @DynamicProtoStub 
     * Function will be removed
     */
}  

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions