This is my setup:
import {bootstrap} from \'angular2/platform/browser\';
import {Component} from \'angular2/core\';
import {LocationStrategy, APP_BASE_HREF,
Same error i had faced but i have solved this as below:
when i write the code like this
{ path: '/formDemo', Component: FormDemo, name: "FormDemo"},
it shows throws the same error you faced but after searching i have found error is in my Component
attribute of routeConfig i.e angular2 thinks we have write a Component annotation in the routeConfig but it accept only exactly one loader,component,redirectto (URL) property. but we have write something else , so when i changed Component
with component
code is working fine.
{ path: '/formDemo', component: FormDemo, name: "FormDemo"},
above line make my code working. It may not help to solve your problem because you have already write component insted of Component but i have posted this for others may be it will help to someone else thanks