Skip to content

Is there way to automatically redirect to index.html? #323

@Ayomits

Description

@Ayomits

I want to redirect to index.html when path /swagger

How can I achieve it ?

func New() {
	r := gin.Default()

	r.GET("/swagger/*any", ginSwagger.WrapHandler(swaggerfiles.Handler))

	_ = ConnectDb(services.DdDsn())

	r.Run(":8080")
}

I'm new in go and I don't know. I tried to write own handler to redirect to index.html, but got error

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions