When available I prefer installing applications via brew as casks, since at least this way if I decide to uninstall it later brew will take care of deleting all of these associated directories.
I remember using an app called AppZapper several years ago which did this but for arbitrary applications. No idea if it’s still around/maintained.
There's `brew uninstall --zap $application`[1], and there's pretty decent coverage, but it's by no means comprehensive. If you feel inclined to contribute, the process is quite streamlined, and there's a helper script[2].
I used Appcleaner[3] for many years, and it's still perfectly serviceable
I'm keeping my eye on Pearcleaner[4], which is additionally open-source and written in Swift.