Adds an example for TodoMVC and refactors some functions into private methods