noob alert
This is weird - trying to create a custom directive in AngularJS, when I write this code:
myModule.directive('myTab', function(){
    console.log('--Inside TAB directive--');
    return 
    {
        template: '<div>Hello World</div>'
    };
});
It throws the exception: TypeError: Cannot read property 'compile' of undefined
However, this code runs fine:
myModule.directive('myTab', function(){
    console.log('--Inside TAB directive--');
    return {
        template: '<div>Hello World</div>'
    };
});
The only difference is the opening curly brace is on the next line in the first code. Is this behaviour normal?
 
    