An Angular 2 Webpack Starter kit featuring Angular 2, Router, TypeScript, and Webpack by AngularClass
PatrickJS on master
Update README.md (compare)
Can I impl select2 for angular2-webpack-starter statup package?
@JoshElias
Is this an appropriate way to use sass?
```
@Component({
...
// webpack.config.common
{
test: /.scss$/,
exclude: /node_modules/,
loader: 'style-loader!css-loader!sass-loader'
}
// inside component
SampleComponent ],
styles: [ require( "./sample.component.scss") ]
})``
I'm getting an error that I'm getting the following error
Expected 'styles' to be an array of strings.`
// all css required in src/app files will be merged in js files
{
test: /\.scss$/,
exclude: /\app.(ios|md|wp).scss$/,//helpers.root('src/app'),
loader: 'raw!postcss!sass'
},
if you have a component and inject a directive into the componenet, is it possible to append that directive attribute to the host element? e.g:
app.component.ts
@Component({
selector: 'app',
encapsulation: ViewEncapsulation.None,
styleUrls: [
'./app.style.css'
],
directives: [
MhScroll
]
index.html
<body>
<app mh-scroll>
loading...
</app>
</body>
this totally mh-scroll works if I append teh directive to the inner component template but not the host itself.
Hello to all! Can you help me please? I've justed forked the angular2-webpack-starter repo and trying to make stylus compilation work.
I've added stylus loader to webpack.common.js:
{
test: /\.styl$/,
exclude: /node_modules/,
loader: 'raw-loader!stylus-loader'
}
and changed app.component.ts
:
styles: [
require('./app.style.styl')
],
It works. But if I use HMR (I start the server like npm run server:dev:hmr
) it doesn't reload when I delete some lines in stylus file. For example:
I add the following code:
body
background red
Result: app updates and changes the background.
I remove two lines added.
Result: I got messages in console, but app does not update.
In console I don't see lines about stylus changes.
And if I reload manually I see the changes.
Why this happens?
hey guys. I'm trying to update my code to use webpack2, simiar to the repo, and I'm getting:
ERROR in [default] C:/dev/RO.View.Dashboard/View/Slb.Prism.RO.View.Dashboard/node_modules/@types/protractor/index.d.ts:1
844:12
Subsequent variable declarations must have the same type. Variable '$' must be of type 'JQueryStatic', but here has typ
e 'cssSelectorHelper'.
.spec.ts
files
describe
is globally imported?