Assigning a function to angular ui-router `onEnter` doesn't work?
<p>The following works.</p>

<pre><code>onEnter: function isAuthed($state, isLogin) {
    ...
}
</code></pre>

<p>But the following doesn't.</p>

<pre><code>function isAuthed($state, isLogin) {
    ...
}

onEnter: isAuthed($state, isLogin)
</code></pre>

<p>Why? Shouldn't they be interchangeable?</p>