1
0
mirror of https://github.com/kataras/iris.git synced 2025-12-17 09:57:01 +00:00

add a DirListRich helper to make the file listing a bit more appealing than its default

Former-commit-id: 1d8338cddac0856be1c9f1e7b6d8d400bee71bef
This commit is contained in:
Gerasimos (Makis) Maropoulos
2020-07-05 23:27:32 +03:00
parent bdfe8de66d
commit 16a6372cc9
3 changed files with 186 additions and 16 deletions

View File

@@ -439,6 +439,10 @@ var (
// Examples can be found at: https://github.com/kataras/iris/tree/master/_examples/file-server
// A shortcut for the `router.FileServer`.
FileServer = router.FileServer
// DirListRich can be passed to `DirOptions.DirList` field
// to override the default file listing appearance.
// Read more at: `core/router.DirListRich`.
DirListRich = router.DirListRich
// StripPrefix returns a handler that serves HTTP requests
// by removing the given prefix from the request URL's Path
// and invoking the handler h. StripPrefix handles a