better directive/controller structure