I have initializer that creates and injects socket.io object into my routes and controllers. I have controller in which i have logic in ‘init’ for handling ‘on’ events that is passed to ember run loop and functions as event handlers inside this controller.
How should i structure that for ember 2.0 ? Should i inject that in components and do all logic that handle events inside components ?
So should i just copy my logic to component init and make handlers for ‘on’ events inside ‘actions’ in this component ?