I know this is a bash thread but zsh/oh-my-zsh will replace !$ with the actual argument when you type a space so you can see and edit it before executing the command.
FWIW, zsh without oh-my-zsh can be configured to do too this with "bindkey ' ' magic-space".