Difference between swagger and loopback for Rest API
Asked Answered
A

2

12

Swagger helps in creating Restful Api, I get that. Where would you use LoopBack, is this another tool for creating Rest api. LoopBack has support swagger 2.0. I am confused here, can they be used interchangeably.

Amparoampelopsis answered 15/12, 2015 at 13:32 Comment(1)
@EricGalluzzo, post it as answer :)Jaguarundi
C
8

Swagger is a documentation framework. If you attach the appropriate annotations to your code, it produces a "live" documentation site that lets users see all your REST services in a visual way, including their request and response formats, with the ability to execute sample calls.

Loopback is a framework that helps you actually write the REST services themselves.

Clough answered 15/12, 2015 at 14:0 Comment(2)
That is not true at all! swagger.io swagger have several tools to build REST frameworks.. is not even for documentations! it generates the api docs, that is a feature... as many others @ericKotz
I agree with @jamesjara. Swagger also generates code scaffolding which gives an initial kick to the development.Schnapp
K
7

Swagger is a powerful open source framework backed by a large ecosystem of tools that helps you design, build, document, and consume your RESTful APIs

You can use the editor , to build the REST specification, without coding, then you use the Swagger generator to convert this human readable file, into real code on more than 10 languages, you can auto generate server and clients.

Kotz answered 22/1, 2017 at 22:22 Comment(1)
Swagger seems more like an api or library. Where loopback is a framework. Reminds me of React vs Angular. Code more with more control vs code less (or more ridged/set-in-stone style) with less flexibility. Would this be a correct assessment?Valley

© 2022 - 2024 — McMap. All rights reserved.