I was working with `slideToggle` today, and just assumed it took an optional boolean value to force the state to be on/off (or down/up as it were) just like `toggle` and `toggleClass`. I obviously was wrong.
I looked at the jQuery source to see how `slideToggle` is handled, and it basically builds an animation where "height", "marginTop", "marginBottom", "paddingTop", "paddingBottom" are all set to the value "toggle".
I worked up a patch that would give `slideToggle` the optional `state` parameter without breaking existing functionality, and committed it to my fork. Before I sent a pull request, I was hoping for feedback or help on the patch I was writing. Obviously, if it is not wanted, then I don't want to spend more time on it either! :)
The only downside I see is that there is now an extra function call to the original `slideToggle` (Moved to _slideToggle) when no state parameter is passed.
You can check out either: