Skip to content
This repository has been archived by the owner on Feb 19, 2021. It is now read-only.

ISSUE-100: Add lazy loading of modules #132

Merged
merged 1 commit into from
Apr 19, 2017
Merged

ISSUE-100: Add lazy loading of modules #132

merged 1 commit into from
Apr 19, 2017

Conversation

mcacek
Copy link
Contributor

@mcacek mcacek commented Apr 19, 2017

Add lazy loading for modules with the exception of timesheet due to an unresolved issue. Upgrade zone.js to fix weird testing messages. Also ad sidenav.

Resolves #100.
Resolves #124.

@mcacek mcacek requested a review from DSchau April 19, 2017 03:52
@@ -28,7 +28,7 @@
"hammerjs": "2.0.8",
"moment": "2.17.1",
"rxjs": "5.1.0",
"zone.js": "0.8.4"
"zone.js": "0.8.5"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We were apparently using an old version of this.. 👎

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Always pretty cool bumping deps, but was this why things were breaking?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is about all that I can give you. angular/angular#15185 I believe it has to do with their approach to overriding the global Error object - https://github.com/angular/zone.js/blob/v0.8.5/CHANGELOG.md

],
providers: [
ExtHttp,
IdentityService,
LocalStorage,
LoginService,
ResponseHandler,
AuthGuard,
ProjectService,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ProjectService is used outside of the project module.

@@ -13,9 +13,8 @@ import {
} from '../core';

@Component({
selector: 'at-login',
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I removed a bunch of selectors that don't do anything. They're routed directly via routers.

@@ -8,9 +8,6 @@ body {
}

.main-container {
margin-left: auto;
margin-right: auto;
max-width: 1024px;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This ended up looking pretty weird with navigation. I'm comfortable saying that we're targeting mobile devices due to our adoption of material.

CoreModule.forRoot(extHttpConfig),
EmployeeModule,
ProjectModule,
TimesheetModule,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I basically just gave up on this for now and included the timesheet module eagerly.

import { NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
import { HttpModule } from '@angular/http';
import { FormsModule } from '@angular/forms';
import { NgModule } from '@angular/core';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was wondering what that CUSTOM_ELEMENTS_SCHEMA was even doing. I think that's for Polymer elements or something :/

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, i'm looking at cleaning that up as well. This has to do with how we're including the angular material modules. If we include them correctly, we'll get rid of these errors.

import { IdentityService } from './identity.service';
import { LocalStorage } from './localStorage';
import { LoginService } from './login.service';
import { ResponseHandler } from './responseHandler.service';
import { ExtHttp } from './extHttp.service';
import { ExtHttpConfig } from './ExtHttpConfig';
import { AuthGuard } from './auth-guard.service';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

Copy link
Contributor

@DSchau DSchau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Add lazy loading for modules with the exception of timesheet due to an unresolved issue. Upgrade zone.js to fix weird testing messages. Also ad sidenav.
@mcacek mcacek merged commit 21c07eb into improving-minnesota:master Apr 19, 2017
@mcacek mcacek deleted the ISSUE-124 branch April 19, 2017 04:43
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add side menu Update application to use lazy route loading
2 participants