Coder Social home page Coder Social logo

Npm install fails about swagger-combined HOT 9 OPEN

thanhson1085 avatar thanhson1085 commented on June 7, 2024
Npm install fails

from swagger-combined.

Comments (9)

thanhson1085 avatar thanhson1085 commented on June 7, 2024

Thank for your report. I have pushed a commit to solve it. Please try to reinstall

npm install --save swagger-combined@latest

from swagger-combined.

CodeJjang avatar CodeJjang commented on June 7, 2024

Not working yet... have you published it to npm?

from swagger-combined.

CodeJjang avatar CodeJjang commented on June 7, 2024

And another issue. I'm using 1.3.4 now.
Cannot reach the swagger UI.

The /docs route works well, but when I access the app in it's default port e.g. http://localhost:3000 then I'm redirected to http://localhost:3000/s?url=/docs but receiving 404 Not Found.

from swagger-combined.

thanhson1085 avatar thanhson1085 commented on June 7, 2024

I think you should use the latest version. In case swagger site does not work, you can use link http://petstore.swagger.io/?url=http://localhost:3000/docs

from swagger-combined.

CodeJjang avatar CodeJjang commented on June 7, 2024

Yeah but I want to be able to serve the UI by myself and not depend on external swagger.io.
Do you have any explanations why it's not working? Maybe I have to configure something which the README missed?
Now I have to install swagger-ui by myself and figure out how to serve it...

from swagger-combined.

thanhson1085 avatar thanhson1085 commented on June 7, 2024

Did you try Installation & Run from Source Code?

from swagger-combined.

CodeJjang avatar CodeJjang commented on June 7, 2024

No I haven't... why would I run from source code? :P
I want to consume the module just as normal node module via npm installing.
By the way, is app.js missing in latest version?

from swagger-combined.

thanhson1085 avatar thanhson1085 commented on June 7, 2024

I removed "install and run via NPM". Actually, Swagger Combined should run as an independent service. app.js now should be routes/app.js

from swagger-combined.

CodeJjang avatar CodeJjang commented on June 7, 2024

Would swagger-ui work in that way?
Because I've just made a service of mine that serves the swagger-ui, and now instead to serve the /docs JSON from the same service I have to lift your service as well, in another port.

Why cant the module just be configured dynamically (without a static .json file which is not so scalable way to configure modules), and then supply methods to get the final combined json? That's more modular, instead of forcing the clients to use the module as an external service for some reason..

from swagger-combined.

Related Issues (16)

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.