fasthttp
fasthttp copied to clipboard
Add "GetString" method for Args
Add "GetString" method for Args
What is the reason you want to add this method? Why can't users of fasthttp just do string(a.Peek(key))
themselves?
What is the reason you want to add this method? Why can't users of fasthttp just do
string(a.Peek(key))
themselves?
-
For most http frameworks, the preferred method for parameter acquisition is Get or GetString, which helps users use fasthttp. For example, go gin: (c * gin. Context) GetString (key string) (s string), https://stackoverflow.com/questions/39265978/get-a-request-parameter-key-value-in-fasthttp
-
When using fasthttp to receive input parameters, there are many string types used, so GetString is used frequently.
I really hope to pass, thank you
But there are no other methods that return strings. Everything returns bytes to prevent allocations. If this is too difficult for someone they really shouldn't be using fasthttp.