The view helper is now container aware.

This allows us to cleanup some boiler plate,
and remove more global references.
Prevent the lock from blowing the stack
RecordArray's are no longer thenable, use events instead.
Update jshintrc to include additional globals
Clean up templates, reorganize search code