Is this still from the WM? Or, when other things turn on and off? For example, the ice maker of the fridge can do the same thing, and the solution is the same - a hammer arrestor. Some toilets turn off quite fast, and can cause it, and, you may have other things in the house with solonoid valves - say your sprinkler system, etc. Also, if the pipes in the house aren't properly anchored, it can make it worse.
Some shower valve designs say to install an arrestor, but that is often overlooked by the installer. That one is a bit harder to overcome cleanly. At least some wall would need to be torn out, hopefully, not a tiled one for access to install one.