Replace template/styles with templateUrl/styleUrls
This commit is contained in:
@@ -2,8 +2,8 @@ import { Component, ViewEncapsulation } from '@angular/core';
|
||||
|
||||
@Component({
|
||||
selector: 'main-app',
|
||||
template: require('../shared/main-app/main-app.component.html'),
|
||||
styles: [require('../shared/main-app/main-app.component.scss')],
|
||||
templateUrl: '../shared/main-app/main-app.component.html',
|
||||
styleUrls: ['../shared/main-app/main-app.component.scss'],
|
||||
encapsulation: ViewEncapsulation.None
|
||||
})
|
||||
export class MainAppComponent { }
|
||||
|
||||
@@ -29,7 +29,7 @@ module.exports = {
|
||||
},
|
||||
module: {
|
||||
loaders: [
|
||||
{ test: /\.ts$/, loader: 'ts-loader', exclude: /node_modules/ },
|
||||
{ test: /\.ts$/, loaders: ['ts-loader', 'angular2-template-loader'], exclude: /node_modules/ },
|
||||
{ test: /\.html$/, loader: 'html-loader?attrs=false' },
|
||||
{
|
||||
test: /\.scss$/,
|
||||
|
||||
Reference in New Issue
Block a user