In short:
@Input
is used for component's tag's attributes.
@Output
is used for component's tag's events.
Think of an HTML input:
<input type="button" onclick="doSomething($event)" ></input>
The input's type
attribute is telling the component how will it render and behave, as a button, as a text input, etc... If you were to use a similar attribute, you'd use the @Input
annotation because you want to insert info into your component.
The input's onclick
attribute/event is considered in Angular 2 an @Ouput
property, because it sends info as an $event
object to external components that might use it.
See:
https://angular.io/docs/ts/latest/guide/template-syntax.html#!#inputs-outputs
Like Chibi mentioned you no longer do:
directives:[CORE_DIRECTIVES, FORM_DIRECTIVES]
in order to use them.