Trim each input

Hi all. Please tell me how best to implement the functionality for removing spaces at the beginning and end of a line for each input? It seems labor-intensive to me to write hooks everywhere. Middleware TrimStrings does not work.
Was this page helpful?