We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
package main import ( "embed" "net/http" "github.com/labstack/echo/v4" "github.com/labstack/echo/v4/middleware" ) //go:embed static var static embed.FS func main() { engine := echo.New() engine.Static("/static", "static") // use embed engine.StaticFS("/staticfs",http.FS(static)) // or engine.StaticFS("/staticfs",static) engine.Start("8080") }
The text was updated successfully, but these errors were encountered:
Static middleware has now support for Filesystem. This was added with #1797 and will be release in v4.3.
e.Use(middleware.StaticWithConfig(middleware.StaticConfig{ Root: ".", Filesystem: http.FS(os.DirFS("../_fixture")), }))
Sorry, something went wrong.
No branches or pull requests
add staticFS
Checklist
Expected behaviour
Actual behaviour
Steps to reproduce
Working code to debug
Version/commit
The text was updated successfully, but these errors were encountered: