lerenn / asyncapi-codegen

An AsyncAPI Golang Code generator that generates all Go code from the broker to the application/user. Just plug your application to your favorite message broker!
Apache License 2.0
95 stars 23 forks source link

Support multi-line descriptions #40

Closed lerenn closed 1 year ago

lerenn commented 1 year ago

For now, when generating a spec with a multi-line description, there is an error as the generated description is commented only on the first line.

This following description:

      description: |
        Status event is happening when there is no more expected event.
        An 'advance' message can be sent after this one.

Will generate this code:

// Description: Status event is happening when there is no more expected event.
An 'advance' message can be sent after this one.

And should generated this instead:

// Description: Status event is happening when there is no more expected event.
// An 'advance' message can be sent after this one.