[fix] Emit the `connection` event before the `data` event
Merge pull request #230 from lpinca/fix/connection-event

Emit the `connection` event before the `data` event