我正在研究 angular2 "2.0.0-rc.1" 但是 zoneJS 给出了以下错误
Error: Uncaught (in promise): Expected 'styles' to be an array of strings.
at resolvePromise (zone.js:538)
at zone.js:515
at ZoneDelegate.invoke (zone.js:323)
at Object.NgZoneImpl.inner.inner.fork.onInvoke (eval at <anonymous> (vendor.js:335), <anonymous>:45:41)
at ZoneDelegate.invoke (zone.js:322)
at Zone.run (zone.js:216)
at zone.js:571
at ZoneDelegate.invokeTask (zone.js:356)
at Object.NgZoneImpl.inner.inner.fork.onInvokeTask (eval at <anonymous> (vendor.js:335), <anonymous>:36:41)
at ZoneDelegate.invokeTask (zone.js:355)
我的代码如下
let styles = require('./dashboard.css');
let template = require('./dashboard.html');
declare var zingchart:any;
@Component({
selector: 'dashboard',
directives: [ RouterLink, CORE_DIRECTIVES, FORM_DIRECTIVES ],
template: template,
styles: [ styles ]
})