Changing to a service/directive setup