Skip to content

Commit bc2204a

Browse files
authored
refactor: use lazy loading throughout the app (angular-split#277)
1 parent 565ef86 commit bc2204a

110 files changed

Lines changed: 1237 additions & 17250 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

README.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,6 @@ Documentation and examples:
1313

1414
#### Previously: [Bertrand Gaillard](https://github.com/bertrandg) (2016 to 2019)
1515

16-
Crossbrowser testing sponsored by [Browser Stack](https://www.browserstack.com)
17-
[<img src="https://camo.githubusercontent.com/a7b268f2785656ab3ca7b1cbb1633ee5affceb8f/68747470733a2f2f64677a6f7139623561736a67312e636c6f756466726f6e742e6e65742f70726f64756374696f6e2f696d616765732f6c61796f75742f6c6f676f2d6865616465722e706e67" alt="Browser Stack" height="31px" style="background: cornflowerblue;">](https://www.browserstack.com)
18-
1916
### License
2017

2118
Apache 2.0

angular.json

Lines changed: 9 additions & 135 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"projects": {
66
"angular-split-app": {
77
"root": "",
8-
"sourceRoot": "src_app",
8+
"sourceRoot": "src",
99
"projectType": "application",
1010
"prefix": "app",
1111
"schematics": {
@@ -18,20 +18,20 @@
1818
"builder": "@angular-devkit/build-angular:browser",
1919
"options": {
2020
"outputPath": "dist/angular-split-app",
21-
"index": "src_app/index.html",
22-
"main": "src_app/main.ts",
23-
"polyfills": "src_app/polyfills.ts",
24-
"tsConfig": "src_app/tsconfig.app.json",
25-
"assets": ["src_app/favicon.ico", "src_app/assets"],
26-
"styles": ["./node_modules/bootstrap/dist/css/bootstrap.min.css", "src_app/styles.scss"],
21+
"index": "src/index.html",
22+
"main": "src/main.ts",
23+
"polyfills": "src/polyfills.ts",
24+
"tsConfig": "src/tsconfig.app.json",
25+
"assets": ["src/favicon.ico", "src/assets"],
26+
"styles": ["./node_modules/bootstrap/dist/css/bootstrap.min.css", "src/styles.scss"],
2727
"scripts": []
2828
},
2929
"configurations": {
3030
"production": {
3131
"fileReplacements": [
3232
{
33-
"replace": "src_app/environments/environment.ts",
34-
"with": "src_app/environments/environment.prod.ts"
33+
"replace": "src/environments/environment.ts",
34+
"with": "src/environments/environment.prod.ts"
3535
}
3636
],
3737
"optimization": true,
@@ -70,132 +70,6 @@
7070
}
7171
}
7272
},
73-
"angular-split-app-lazy": {
74-
"root": "",
75-
"sourceRoot": "src_lazy_app",
76-
"projectType": "application",
77-
"prefix": "app-lazy",
78-
"schematics": {
79-
"@schematics/angular:component": {
80-
"style": "scss"
81-
}
82-
},
83-
"architect": {
84-
"build": {
85-
"builder": "@angular-devkit/build-angular:browser",
86-
"options": {
87-
"outputPath": "dist/angular-split-app/lazy",
88-
"index": "src_lazy_app/index.html",
89-
"main": "src_lazy_app/main.ts",
90-
"polyfills": "src_lazy_app/polyfills.ts",
91-
"tsConfig": "src_lazy_app/tsconfig.app.json",
92-
"assets": ["src_lazy_app/favicon.ico", "src_lazy_app/assets"],
93-
"styles": ["src_lazy_app/styles.scss"],
94-
"scripts": []
95-
},
96-
"configurations": {
97-
"production": {
98-
"fileReplacements": [
99-
{
100-
"replace": "src_lazy_app/environments/environment.ts",
101-
"with": "src_lazy_app/environments/environment.prod.ts"
102-
}
103-
],
104-
"optimization": true,
105-
"outputHashing": "all",
106-
"sourceMap": false,
107-
"extractCss": true,
108-
"namedChunks": false,
109-
"aot": true,
110-
"extractLicenses": true,
111-
"vendorChunk": false,
112-
"buildOptimizer": true,
113-
"budgets": [
114-
{
115-
"type": "initial",
116-
"maximumWarning": "2mb",
117-
"maximumError": "5mb"
118-
}
119-
]
120-
}
121-
}
122-
},
123-
"serve": {
124-
"builder": "@angular-devkit/build-angular:dev-server",
125-
"options": {
126-
"browserTarget": "angular-split-app-lazy:build"
127-
},
128-
"configurations": {
129-
"production": {
130-
"browserTarget": "angular-split-app-lazy:build:production"
131-
}
132-
}
133-
}
134-
}
135-
},
136-
"angular-split-app-lazy2": {
137-
"root": "",
138-
"sourceRoot": "src_lazy_app2",
139-
"projectType": "application",
140-
"prefix": "app-lazy2",
141-
"schematics": {
142-
"@schematics/angular:component": {
143-
"style": "scss"
144-
}
145-
},
146-
"architect": {
147-
"build": {
148-
"builder": "@angular-devkit/build-angular:browser",
149-
"options": {
150-
"outputPath": "dist/angular-split-app/lazy2",
151-
"index": "src_lazy_app2/index.html",
152-
"main": "src_lazy_app2/main.ts",
153-
"polyfills": "src_lazy_app2/polyfills.ts",
154-
"tsConfig": "src_lazy_app2/tsconfig.app.json",
155-
"assets": ["src_lazy_app2/favicon.ico", "src_lazy_app2/assets"],
156-
"styles": ["src_lazy_app2/styles.scss"],
157-
"scripts": []
158-
},
159-
"configurations": {
160-
"production": {
161-
"fileReplacements": [
162-
{
163-
"replace": "src_lazy_app2/environments/environment.ts",
164-
"with": "src_lazy_app2/environments/environment.prod.ts"
165-
}
166-
],
167-
"optimization": true,
168-
"outputHashing": "all",
169-
"sourceMap": false,
170-
"extractCss": true,
171-
"namedChunks": false,
172-
"aot": true,
173-
"extractLicenses": true,
174-
"vendorChunk": false,
175-
"buildOptimizer": true,
176-
"budgets": [
177-
{
178-
"type": "initial",
179-
"maximumWarning": "2mb",
180-
"maximumError": "5mb"
181-
}
182-
]
183-
}
184-
}
185-
},
186-
"serve": {
187-
"builder": "@angular-devkit/build-angular:dev-server",
188-
"options": {
189-
"browserTarget": "angular-split-app-lazy2:build"
190-
},
191-
"configurations": {
192-
"production": {
193-
"browserTarget": "angular-split-app-lazy2:build:production"
194-
}
195-
}
196-
}
197-
}
198-
},
19973
"angular-split": {
20074
"root": "projects/angular-split",
20175
"sourceRoot": "projects/angular-split/src",

cypress/integration/1.simple.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ context('Simple split example page tests', () => {
88
const GUTTER = 11
99

1010
beforeEach(() => {
11-
cy.visit('/#/examples/simple-split')
11+
cy.visit('/examples/simple-split')
1212
})
1313

1414
it('Display initial state', () => {

cypress/integration/10.lazy.spec.js

Lines changed: 0 additions & 66 deletions
This file was deleted.

cypress/integration/2.minmax.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ context('Min & max splits example page tests', () => {
88
const GUTTER = 30
99

1010
beforeEach(() => {
11-
cy.visit('/#/examples/min-max-split')
11+
cy.visit('/examples/min-max-split')
1212
})
1313

1414
it('Display initial state', () => {

cypress/integration/3.nested.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ context('Nested splits example page tests', () => {
88
const GUTTER = 11
99

1010
beforeEach(() => {
11-
cy.visit('/#/examples/nested-split')
11+
cy.visit('/examples/nested-split')
1212
})
1313

1414
it('Display initial state', () => {

cypress/integration/4.sync.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ context('Sync splits example page tests', () => {
88
const GUTTER = 11
99

1010
beforeEach(() => {
11-
cy.visit('/#/examples/sync-split')
11+
cy.visit('/examples/sync-split')
1212
})
1313

1414
it('Display initial state', () => {

cypress/integration/5.style.spec.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

cypress/integration/7.click.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ context('Gutter click example page tests', () => {
88
const GUTTER = 10
99

1010
beforeEach(() => {
11-
cy.visit('/#/examples/gutter-click-roll-unroll')
11+
cy.visit('/examples/gutter-click-roll-unroll')
1212
})
1313

1414
it('Display initial state', () => {

cypress/integration/9.geek.spec.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ context('Geek demo example page tests', () => {
88
const GUTTER = 11
99

1010
beforeEach(() => {
11-
cy.visit('/#/examples/geek-demo')
11+
cy.visit('/examples/geek-demo')
1212
})
1313

1414
it('Display initial state', () => {

0 commit comments

Comments
 (0)