title: How can I pass variable to ng-init call?
body: <p>At my controller's I have created a function that's responsible for initialising the state of the scope. It is then called at <code>ng-init</code> like so: <code>... ng-init="init(value)"</code> where <code>value</code> is some variable from the global scope. The problem is - it doesn't work. Doesn't angular allow to pass variables? Is anything within <code>ng-init</code> only evaluated without any context and I have to prepare a string?</p>