cyclosproject / ng-openapi-gen

An OpenAPI 3.0 codegen for Angular
MIT License
403 stars 134 forks source link

NgOpenApiGen class to be extendable to create other/custom templates #244

Open ak99372 opened 2 years ago

ak99372 commented 2 years ago

Can we make the write method protected instead of private so the NgOpenApiGen can be extended with additional custom outputs/templates. Something like this:

export class CustomGen extends NgOpenApiGen {
    generate(): void {
        super.generate();
        this.write('custom', {...} , 'custom');
    }
}

write is private so above doesn't transpile.

luisfpg commented 1 year ago

Sorry, I'm having little to no time to dedicate to this project. If you make a PR, I'll try to include it in the next release.