Generalized Whenever monad on the internal monad

In preparation for a possible JavaScript GUI