Added basic support for events.
Refactored the data and template fetching to be completely async and non-depending on each other.