PatrickJS / angular-hmr

:fire: Angular Hot Module Replacement for Hot Module Reloading
https://patrickjs.com
Apache License 2.0
506 stars 45 forks source link

Typings error (when hmr-loader added) #44

Closed glebmachine closed 7 years ago

glebmachine commented 7 years ago

What's wrong?

When @angularclass/hmr-loader added to loader list following error appears:

....   
ERROR in [at-loader] frontend/bootstrap.browser.ts:6:87 
    Cannot find name 'module'.

ERROR in [at-loader] frontend/bootstrap.browser.ts:6:108 
    Cannot find name 'module'.

ERROR in [at-loader] frontend/bootstrap.browser.ts:6:190 
    Cannot find name 'module'.

ERROR in [at-loader] frontend/bootstrap.browser.ts:6:248 
    Cannot find name 'module'.

ERROR in [at-loader] frontend/bootstrap.browser.ts:6:330 
    Cannot find name 'module'.

ERROR in [at-loader] frontend/bootstrap.browser.ts:6:362 
    Parameter 'status' implicitly has an 'any' type.

ERROR in [at-loader] frontend/bootstrap.browser.ts:6:491 
    Cannot find name 'module'.

ERROR in [at-loader] frontend/bootstrap.browser.ts:6:523 
    Parameter 'err' implicitly has an 'any' type.

ERROR in [at-loader] frontend/bootstrap.browser.ts:6:528 
    Parameter 'outdatedModules' implicitly has an 'any' type.

ERROR in [at-loader] frontend/bootstrap.browser.ts:6:681 
    Cannot find name 'module'.

ERROR in [at-loader] frontend/bootstrap.browser.ts:6:715 
    Parameter 'dependencies' implicitly has an 'any' type.

ERROR in [at-loader] frontend/bootstrap.browser.ts:6:810 
    Cannot find name 'module'.

ERROR in [at-loader] frontend/bootstrap.browser.ts:6:844 
    Parameter 'store' implicitly has an 'any' type.

Details and repro

How to reproduce from scratch:

Thank you guys) 🍺

jsgoupil commented 7 years ago

https://github.com/AngularClass/angular2-hmr-loader/issues/6

glebmachine commented 7 years ago

Thanks! It helps me to fix. @angularclass/hmr-loader should be first element of rules array.

Check this commit for working example: https://github.com/glebmachine/angular2-boilerplate/commit/d777cc281629b69443c0718463eb37daa9040c95#diff-2dc6f58c1d73affef225ba6007bb51afL28