update to rc.5
merge changes from https://github.com/AngularClass/angular2-seed
Angular 2 Seed will be the simple version of this repo. Both will be updated to Webpack 2
Great!
I have a simple version of the starter here https://github.com/AngularClass/angular2-seed that's updated to rc.5 it's where I experiment for changes in this repo
I tried to use RC5 and ran into an issue with uri.match is not a function, which is caused by _split being called on moduleId by angular, which in the case of webpack is a number.
https://github.com/angular/angular/pull/10595 is a PR created by @mhamel06 to fix the issue.
don't use moduleId in webpack
How about dependencies being used in the project that are using moduleId that we have no control over?
@shahmirn are they public deps on github? if so can you give me a link to the repo. You would use a loader to rewrite it and remove the moduleId but I need to create it.
sorry not at computer now but I think my issue may have been from the material repo, since I still had the issue after removing my moduleIDs. this is with the latest Ng module version. https://github.com/angular/material2/blob/master/src/components/sidenav/sidenav.ts
I think ensuring that the _split function is only called with the expected type should fix the core issue.
@mhamel06 @shahmirn ok fixed via https://github.com/AngularClass/angular2-seed/commit/84aacc18682bbe38631cd3c457d9e90944d6fd0e
when rc5 will be updated in this project? @gdi2290 thank you
@gdi2290 the seed repo uses webpack 2, is it planned to update this starter repo to webpak 2 as well?
yup this repo will be updated to webpack2 and rc5
eta?
Looking forward to this, if you'd like me or the 100 other people here waiting for this to help, let us know how!
I noticed when trying to update my own project that the hot loading stuff might be a bit ?? with rc5. Because you have to declare all of the components in a single place. Are we going to make multiple modules for a project, maybe? Seems really a lot more complicated than before.
Agree with @paralin , I also concern that if we're putting all the deps in one place, isn't it break the encapsulation of each component as they might depend on other libs that are not imported.
I'm currently playing with this repo, and I see that using modules changed pretty much everything in the app organization. Hope to see the updated version soon, this is a really good starting point for new apps.
Has anyone hacked together a workaround that will allow use with rc5 for existing rc4 applications?
I can work on a webpack loader that will convert code from rc4 to rc5 NgModule
I would prefer to see how we can integrate aot compilation into webpack build process.
In the release notes they said something like "rc4 apps should still work" but they really don't, I don't see how they think it's a good idea to release another rc and just completely nuke the entire workflow everyone had been using, I mean it makes sense in unstable development software but these are release candidates, not alpha or beta versions. And the fact that we have to declare all of our modules at start means we can't shard with webpack anymore, as far as I can tell.
There's a pretty big discussion on this on an issue on the angular repo, I don't have the link right now, but it's possible they will change a lot of these things before rc6.
At the moment I'm a resigned to staying with rc4 until they fix this stuff.
Actually rc5 is made to be compatible with rc4. Anyway my app worked fine after some adjustments, just have to change about everything from bootstrap to the router, enclose components in modules, change the way directives are loaded and it should work.