186 Commits

Author SHA1 Message Date
René Werner
5745dfe1ac add docs for dynamic routing 2023-08-27 14:29:17 +02:00
René Werner
57aef091c4 add docs for dynamic routing 2023-08-27 14:27:40 +02:00
Jian Lim
35797e6639
📝 Docs: update io/ioutil package to io package (#2589)
Deprecation of io/ioutil
2023-08-22 08:57:00 +02:00
M. Efe Çetin
1dea615ddf
🔥 add config to enable splitting by comma in parsers (#2560)
* 🔥 add config to enable splitting by comma in parsers

🔥 add config to enable splitting by comma in parsers

* optimize if statements, remove escape char support

optimize if statements, remove escape char support

* update
2023-08-21 09:44:02 +02:00
Jacob
892b23bd46
Add custom data property to favicon middleware config (#2579)
* Add custom data property to favicon middleware

* Update favicon middleware docs

* Fix formatting
2023-08-17 15:04:53 +02:00
João Victor Oliveira Couto
f29f39b1b3
fix: Decompress request body when multi Content-Encoding sent on request headers (#2555)
* 🔧 feat: Decode body in order when sent a list on content-encoding

* 🚀 perf: Change `getSplicedStrList` to have 0 allocations

* 🍵 test: Add tests for the new features

* 🍵 test: Ensure session test will not raise an error unexpectedly

* 🐗 feat: Replace strings.TrimLeft by utils.TrimLeft

Add docs to functions to inform correctly what the change is

* 🌷 refactor: Apply linter rules

* 🍵 test: Add test cases to the new body method change

* 🔧 feat: Remove return problems to be able to reach original body

* 🌷 refactor: Split Body method into two to make it more maintainable

Also, with the previous fix to problems detected by tests, it becomes really hard to make the linter happy, so this change also helps in it

* 🚀 perf: Came back with Header.VisitAll, to improve speed

* 📃 docs: Update Context docs
2023-08-06 17:23:37 +02:00
M. Efe Çetin
e91b02b345
📝 docs: fix wrong JSON docs (#2554) 2023-07-26 13:27:45 +02:00
Renan Bastos
3e5743bcac
doc: Improve *fiber.Client section (#2553)
* wip

* doc: Improve *fiber.Client section

Enhanced the documentation for the *fiber.Client section, providing
a clear and concise example to help users better understand its usage.

* chore: refactor message about example
2023-07-25 20:15:23 +02:00
René Werner
443804e95d improved the config section of the middleware readme´s 2023-07-24 17:03:11 +02:00
RW
51ea636b60
improved the config section of the middleware readme´s (#2552) 2023-07-24 16:46:50 +02:00
Lev Saminskij
5d74725a69
📝 added documentation about ctx Fresh (#2549)
added documentation about ctx Fresh
2023-07-24 15:36:18 +02:00
Precious Luke
2c8c4a6545
Update intro.md (#2550)
Since we are using port 3000, it ideal to maintain that throughout in order not to confuse beginners
2023-07-22 18:42:48 +03:00
RW
c0116f445f
Update ctx.md
Add hint for references to GetReqHeaders
2023-07-20 16:47:39 +02:00
RW
3b08646abf
Update ctx.md
Add additional documentation for GetRespHeaders
2023-07-20 16:43:49 +02:00
Štefan Baebler
f1ff0f45c8
📚 Doc: Fixed link to slim template engine (#2547)
docs: fixed link to slim template engine
2023-07-18 11:57:06 +02:00
RW
f6446ab0b9
Update log.md 2023-07-16 16:18:23 +02:00
f1rstmehul
08099b0635
📚 Docs: Fix link (#2542)
fix link
2023-07-15 20:20:29 +02:00
RW
a9933f50c5
Update intro.md 2023-07-09 18:52:51 +02:00
René Werner
032bde9452 use new template docs in fiber docs 2023-07-08 21:33:15 +02:00
z3ntl3
80fc222646
- fixed validation-guide (#2517)
* - fixed validation-guide

* 06/23/2023 14:39:08 - small update

* 06/23/2023 14:51:31

* 06/23/2023 14:53:47

* ()

* ()

* 06/25/2023 18:07:46 fix naming

* 06/26/2023 09:31:57

* 06/26/2023 09:35:39 - fix indentation

* 06/26/2023 09:37:48 - formatted with go fmt

* 06/27/2023 19:24:42 - update to v10

* 06/27/2023 19:27:17 - update validator to v10

* 06/27/2023 23:38:38 - fix var name

* 06/27/2023 23:40:47 - fix var name
2023-06-28 00:49:32 +03:00
Iliya
5c1e8a9cff
📚 Docs: fix bad documentation on queries function (#2522) 2023-06-27 17:20:50 +02:00
Ruan Heyns
f68ec0dfbb
Update ctx.md: Add a warning on security implications when using X-Forwarded-For improperly (#2520)
Update ctx.md

Add a warning on security implications when using X-Forwarded-For improperly
2023-06-26 10:24:50 +02:00
Jiun Lee
fefc533834
🚀 Add Logger interface and fiberlog (#2499)
* add log for fiber

* replace log in fiber

* add Log use to adapt for log libraries

* Update app.go

Co-authored-by: Tomás Warynyca <41587659+tomaswarynyca@users.noreply.github.com>

* wip: add log docs

* add WithLogger use to print key and value

* remove CtxLogger and add WithContext use to bind Context

* fix errcheck

* fix errcheck

* update log.md

---------

Co-authored-by: Tomás Warynyca <41587659+tomaswarynyca@users.noreply.github.com>
2023-06-26 08:16:57 +02:00
W. Xiaoyun
040aac94c6
✏️ Fix: typo in ctx.md (#2516)
Fix: typo in ctx.md
2023-06-23 11:44:52 +02:00
RW
1603a148fe
Update logger.md 2023-06-22 13:21:14 +02:00
RW
b308b2b7a6
Update logger.md
correct spacings
2023-06-22 13:07:33 +02:00
cmd777
1b060cb150
🩹 Fix: default logger color behaviour (#2513)
* Fix logger colors

* Fix tests
Basically add ˙enableColors: true˙ back to default config
2023-06-22 13:06:37 +02:00
RW
2eaeb0f3f7
Update hooks.md
correct docs syntax error
2023-06-19 13:24:41 +02:00
SamanDev
ed95fa8c7e
🔥 Feature: add ability to print custom message on startup (#2491)
* feat: add a variadic parameter on OnListenHandler

* feat: accept a variadic ListenData in startupProcess parameters

* feat: add startupProcess variadic ListenData to function

* refactor: use runOnListenHooks instead of startupProcess for run onListenHooks

* refactor: remove variadic to make codes straightforward

* fix: add listen data to runOnListenHooks

* test: add listenData parameter to OnListen tests

* docs: update OnListen docs

* fix: remove unused codes

* docs: add tabs to onListen hook example

* docs: add if statement to docs example

* docs: replace fmt with log

* docs: fix return value of example

* docs: make 0.0.0.0 string a constant

* fix: change type of TLS from string to bool

* fix: return bool instead of a string

* docs: update example with new TLS type

* fix: change name tls to isTls to prevent shadowing tls variable

* style: make syntax of onListen example shorter

* refactor: remove unused no-lint comment

* refactor: change isTls to isTLS

* fix: add nolint for isTLS bool param

* Update listen.go

---------

Co-authored-by: M. Efe Çetin <efectn@protonmail.com>
2023-06-19 13:11:22 +02:00
我的名字叫浩仔
3dc9e1df80
🐛 bug: fix docs api fiber custom config (#2510)
fix: docs api fiber custom config

Co-authored-by: haoc <haoc@opera.com>
2023-06-19 12:22:55 +02:00
RW
9bcdb560dc
Update ctx.md 2023-06-19 10:49:25 +02:00
RW
204b01aeb2
Update ctx.md 2023-06-19 10:47:45 +02:00
RW
fa5935b7e9
Update ctx.md
reformat queries docu
2023-06-19 10:43:15 +02:00
RW
f86423d625
Update ctx.md
reformat ctx.Queries() example
2023-06-19 10:41:53 +02:00
Iliya
d87065f5f2
🚀 FEATURE: add queries function (#2475)
* 🚀 FEATURE: add queries method

* 📚 DOCS: add documents for queries method.

* 🩹 Fix: fix wrap error returned from Queries function

* 🚨 tests: add url encoded tests

* 🔥 feature: add url encoded support for queries

* 🩹 Fix: fix wrap error returned from Queries function

* ♻️ Refactor: change error message of url.QueryUnescape

* ♻️ Refactor: refactor of mapping key and value queries

* 🚨 Test: Validate to fail parse queries

* 🚨 Test: Add benchmark test for Queries

* 🩹 Fix: remove parsing for encoded urls

* ♻️ Refactor: change string function to c.app.getString fucntion

Co-authored-by: cmd777 <83428931+cmd777@users.noreply.github.com>

* ♻️ Refactor: change name of benchamark function ctx queries

Co-authored-by: leonklingele <git@leonklingele.de>

* ♻️ Refactor: remove empty lines

Co-authored-by: leonklingele <git@leonklingele.de>

* Revert "♻️ Refactor: change string function to c.app.getString fucntion"

This reverts commit 28febf9e602bb13f0761169c26f264e4687da660.

* 📚 Docs: add documents for queries method

* 🚨 Tests: add more tests for queries function

* ♻️ Refactor: change string function to c.app.getString function

* 🚨 Tests: add more test for queries function

* 📚 Docs: add more documents to queries function

---------

Co-authored-by: cmd777 <83428931+cmd777@users.noreply.github.com>
Co-authored-by: leonklingele <git@leonklingele.de>
2023-06-12 07:51:57 +02:00
M. Efe Çetin
f5d2abb948
📝 docs: update version of html template (#2505) 2023-06-10 17:16:11 +03:00
Jason McNeil
0f5ffed3cc
🐛fix: update getOffer to consider quality and specificity (#2486)
* feat: getOffer consider q value and specificity

* fix: ignore q=0

* fix: float

* test: client-prefered order and q=0 not acceptable

* fix: always use my insertion sort.

* fix: sort.SliceStable if > 20

* fix: zero allocations

* perf: optimize the sort

* chore: fix lint issue

* fix: consider order

* chore: fix test func name

* chore: fix helper test func name

* chore: revert fix

* perf: use fasthttp.ParseUfloat

* test: GetOffer and SortAcceptedTypes

* chore: remote nil check

* test: sortAcceptedTypes

* fix: use utils.UnsafeBytes

* docs: update docs for fiber PR #2486

* docs: update docs for fiber PR #2486

* test: add test from docs

* fix: yaml
2023-06-07 17:51:45 +02:00
Anzhi
06ef450a8a
🚀 Add DisableColors to set the default output format (#2493)
Add DisableColor for default logger format
2023-06-05 13:20:45 +02:00
leonklingele
c56b4e66a0
middleware/adaptor: allow to convert fiber.Ctx to (net/http).Request (#2461) 2023-05-15 13:04:58 +02:00
M. Efe Çetin
c7c37d9b50
♻️ refactor: merge some external middlewares to core (#2453)
* ♻️ refactor: merge adaptor, helmet, keyauth, redirect, rewrite middlewares to core

* fix linting issues

* fix linting issues

* fix linting issues

* update
2023-05-10 08:01:49 +02:00
bcd
3c3f12b76c
[Feature]: Add filesystem config contentTypeCharset support (#2438)
* Update filesystem.go

* Update filesystem_test.go

* Update filesystem.md

* fmt
2023-05-02 08:40:20 +02:00
RW
ee2b13c8c0
Update timeout.md 2023-04-14 12:18:00 +02:00
RW
41b08b6cb0
Update faq.md 2023-04-14 11:36:57 +02:00
cmd777
3b7a7d491b
📚 Docs: Fix import and comma issues (#2410)
Fix import and comma issues
2023-04-13 12:32:39 +08:00
James Lucas
866d5b7628
feat(cors): Added new 'AllowOriginsFunc' function. (#2394)
*  feat(cors): Added new 'AllowOriginsFunc' function.

* feat(cors): Added warning log for when both 'AllowOrigins' and 'AllowOriginsFunc' are set.

* feat(docs): Updated docs to include note about discouraging the use of this function in production workloads.

---------

Co-authored-by: RW <rene@gofiber.io>
2023-04-11 10:24:29 +02:00
RW
fcf708dfc2
Update routing.md 2023-04-10 12:31:49 +02:00
RW
c396d2aa45
Update grouping.md 2023-04-10 12:28:57 +02:00
cmd777
8b1f9260a3
📚 Docs: Fix typos, and make middleware documentation more consistent (#2408)
Fix typos, and make docs more consistent
This fixes several typos in the ISSUE_TEMPLATES, as well as improve
their readability, also makes the documentation markdowns more
consistent
2023-04-10 10:48:12 +08:00
Hakan Kutluay
22b407e2e7
🐛 [Bug-Fix] add original timeout middleware (#2367)
* add original timeout middleware

* fix linter issues

* deprecate original timeout middleware

* update timeout middleware documentation
2023-04-09 16:05:51 +02:00
Juan C. Yamacho H
562d15db86
🚀 Feature: Public ShutdownWithContext (#2407)
* feat: public shutdown with context

* docs: add server shutdown option

* chore: revert spacing changes

* test: app shutdown with context
2023-04-09 21:08:03 +08:00