JS helper class for event-driven Websockets with Brainsocket & Laravel