Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How can I import from a yaml file #78

Closed
delgec opened this issue Feb 24, 2022 · 1 comment
Closed

How can I import from a yaml file #78

delgec opened this issue Feb 24, 2022 · 1 comment

Comments

@delgec
Copy link

delgec commented Feb 24, 2022

Hello everyone

I just want to import a yaml file for UI. I tryed but I got an error.

How can I make it?

Thanks

	e := echo.New()
	e.Use(middleware.Static("/static"))
	url := echoSwagger.URL("static/openapi.yaml")
	e.GET("/swagger/*", echoSwagger.EchoWrapHandler(url))

Output Screenshot:

Screenshot from 2022-02-23 12-28-21

@ubogdan
Copy link
Contributor

ubogdan commented Feb 24, 2022

It's quite normal behavior since you didn't do anything to serve the file "static/openapi.yaml" via a static handler.

This is not a echo-swagger issue.

@delgec delgec closed this as completed Feb 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants