I am hoping someone can clear this up for me. I am assuming there is an easy answer to this. But if its out on the internet I can't seem to find it. Keep in mind, I have little angular 1 experience, so I apologize if I am missing something obvious.
I have seen the following examples out there for creating a template in Angular 2.
//Example 1
@Component({
selector: 'my-app'
})
@View({
template : '<p></p>'
})
As I understand it, the above example is the same as this.
// Example 2
@Component({
selector: 'my-app',
template: '<p></p>'
})
According to this https://angular.io/docs/ts/latest/api/core/View-decorator.html and this @Directive v/s @Component in angular2
So is there any good reason to create templates like the first example vs the second where @View
seems to be implicitly set via @Component
using "template:"?