I have set up Vim to trigger reformatting on save using ALE, but sometimes that doesn't fly very well, and would like to disable it manually. But remembering what the right incantations are is always impossible, needing to grep my dotfiles for clues, so I'd like to be able to toggle it, say, using Alt-F8. That means some kind of vimscript function that just sets
let g:ale_fix_on_save = 0.
How would such a function look and how do I bind it?
(Bonus points for showing how to toggle the value)