GithubHelp home page GithubHelp logo

Comments (2)

vanderlee avatar vanderlee commented on May 25, 2024

I can't change the default behaviour due to backwards compatibility, but perhaps an option could be added to change this. Something like an enableLinebreaks() or such.
Alternatively, perhaps we can come up with a way to specify this in the @rest\description syntax itself. Are there any precedents for such kind of behaviour in other frameworks?

from phpswaggergen.

rlanvin avatar rlanvin commented on May 25, 2024

I don't know. It's tricky because sometimes you might want to break the lines just to have a more readable source code (e.g. you want to limit the lines to 80 characters) while sometimes you want the line break to be kept for the Markdown formatting for Swagger UI.

There is somewhat the same problem if you use a YAML file directly: one line break is ignored (same behavior has your lib), you need an additional empty line to count as a line break in Swagger UI (so basically \n\n becomes \n in the end result).

from phpswaggergen.

Related Issues (19)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.