I think the first is the preferred option - your HomeModule groups like 
components together. Later you may have an "AwayModule" containing 
SumAwayComponent1 etc. which you will then import into AppModule.
Thus, when Appmodule loads, it can lazy-load either Home or Away depending 
on whatever business logic separates the two.

.\\axxx

On Tuesday, 23 August 2016 00:50:11 UTC+10, F. Zafer KAYIKÇILAR wrote:
>
> I'm pretty new to Angular and these RC changes really hard for me. Like 
> NgModules. I understood how to put main components to AppModule. It's ok 
> but for example i have sub components that are used in Home component. 
>
> Should i make a HomeModule (including SubHomeComponent1, 
> SubHomeComponent2) and import it to AppModule 
> OR
> Should i put everything (including HomeComponent, SubHomeComponent1, 
> SubHomeComponent2 etc.) to AppModule? 
>

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to