You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The reason that I'm reporting here is that, I'm also trying another template -- https://github.com/create-go-app/fiber-go-template/, which seems to be doing no difference than what you're doing regarding CORS:
package middleware
import (
"github.com/gofiber/fiber/v2""github.com/gofiber/fiber/v2/middleware/cors""github.com/gofiber/fiber/v2/middleware/logger"
)
// FiberMiddleware provide Fiber's built-in middlewares.// See: https://docs.gofiber.io/api/middlewarefuncFiberMiddleware(a*fiber.App) {
a.Use(
// Add CORS to each route.cors.New(),
// Add simple logger.logger.New(),
)
}
Yet, its CORS/swagger is working just fine:
What could possibly cause the difference?
How can I make the swagger work out of the box please?
The text was updated successfully, but these errors were encountered:
Description of the bug
When testing the API from swagger, I always get "Failed to fetch" error.
Doing it on CLI is fine though.
Steps To Reproduce
Additional Information
The reason that I'm reporting here is that, I'm also trying another template -- https://github.com/create-go-app/fiber-go-template/, which seems to be doing no difference than what you're doing regarding CORS:
Yet, its CORS/swagger is working just fine:
What could possibly cause the difference?
How can I make the swagger work out of the box please?
The text was updated successfully, but these errors were encountered: