Hooks for javascripts done right.