Difference between the 'controller', 'link' and 'compile' functions when defining a directive Difference between the 'controller', 'link' and 'compile' functions when defining a directive angularjs angularjs