Commit Graph

21 Commits (843fab720ed83b426a2ae3257ff167d8aa0efc1c)

Author SHA1 Message Date
Tom 21c9fb4936
🔥 Add `PathPrefix` parameter to `filesystem` middleware (#1326)
See #1308

This adds a parameter called `PathPrefix` to `filesystem.Config`
that is prepended to any filepath being read from
`filesystem.Root`.

Intended to be used with Go 1.16's `embed.FS` type.

Signed-off-by: Tom <tom@tdpain.net>
2021-05-12 08:58:01 +02:00
iRedMail a179c6665c
✏️ FS MW: add example of embedding directory (#1197)
Co-authored-by: hi019 <65871571+hi019@users.noreply.github.com>
2021-03-02 12:12:40 -05:00
circa10a c1386ff6c5 📝 docs: add embed example for go 1.16 2021-02-18 09:38:05 -06:00
hi019 bc7b240158 improve mw 2020-11-21 12:36:16 -05:00
renanbastos93 8ad1d16f3a 💉 test: using sendfile method 2020-10-28 11:44:14 -03:00
Fenny c78a5013c0 update sendfile
Co-Authored-By: Renan Bastos <renanbastos.tec@gmail.com>
2020-10-28 05:37:07 +01:00
renanbastos93 1b4c0432c0 🔪 change signature method 2020-10-28 01:25:08 -03:00
renanbastos93 e41bf7f08f 🚀 start poc 2020-10-28 01:11:49 -03:00
Fenny d5dbad6476 🧹 remove unused key 2020-10-27 08:14:58 +01:00
Fenny 726600f577 🧳 add maxAge to filesystem mw 2020-10-27 08:12:37 +01:00
Fenny 6395e1933c ⚠ add disclaimer to fs 2020-09-27 13:14:00 +02:00
Fenny eaf32fa4da ⚠ add warning to FileSystem 2020-09-27 13:11:51 +02:00
kiyon 616ff8f532 👷 remove unnecessary fiber app config 2020-09-17 13:41:06 +08:00
kiyon 30783dd25d 👷 add filesystem test cases 2020-09-17 12:56:11 +08:00
Fenny d0c541ee2b 📘 add pkger example 2020-09-16 15:38:11 +02:00
kiyon e13411e184 👷 improve mw test cases
add Next test case
2020-09-16 09:44:05 +08:00
Stephan Deumier 58d657cb0a
Update filesystem.go 2020-09-14 16:12:46 +02:00
Fenny 7576f806c9 📖 update readme 2020-09-14 14:21:13 +02:00
Fenny 2768ea2a77 🙌 make utils public
Co-Authored-By: RW <7063188+ReneWerner87@users.noreply.github.com>
2020-09-14 12:12:29 +02:00
Fenny a3cac71ae8 🔦 move utils to internal 2020-09-14 09:09:06 +02:00
Fenny ec5d66e7a8 v2 2020-09-13 11:20:11 +02:00