Azure / autorest.typescript

Extension for AutoRest (https://github.com/Azure/autorest) that generates TypeScript code. The transpiled javascript code is isomorphic. It can be run in browser and in node.js environment.
MIT License
177 stars 75 forks source link

[v3] Support source code transformations #1073

Open sarangan12 opened 3 years ago

sarangan12 commented 3 years ago

In the earlier versions of Autorest (V2), we used to have logic for source code transformations. For example, you can find the transformations set in https://raw.githubusercontent.com/Azure/azure-rest-api-specs/master/specification/search/data-plane/Azure.Search/readme.md. (Search for source-file-csharp)

But, in the latest versions of Autorest (V3), the source code transformations are not supported (Swagger Transformations are supported) I have confirmed with @timotheeguerin the same.

Based on that discussion, I am creating this issue to track the work to include source code transformations.

timotheeguerin commented 3 years ago

Sorry, when I said that this was an issue on the generator side. The old generator pipeline definition used to define the transform stage but they don't anymore.

See old csharp definition https://github.com/Azure/autorest.csharp/tree/master it has this step

  csharp/transform:
    input: simplifier
    output-artifact: source-file-csharp
    scope: scope-transform-string
sarangan12 commented 3 years ago

Moving to backlog.