What is the @component means?


         template: `<button ion-button [navPush]="pushPage" [navParams]="params">Go</button>`,

        selector: 'page-home',

        templateUrl: 'bpjs.html',


I have a question about @component:

What is template for?

Also, is selector always begin with page- and ended with the file name? I wonder what is page-home means since the file name is bpjs

but the file works.

Really summarized, the selector is the “tag” you would have to use in your templates. Let’s say you have a component selector which is your own calendar called “app-my-calendar” then if you want to use it in your templates you gonna type <app-my-calendar></app-my-calendar>

About definition of the component: https://angular.io/api/core/Component