This guide applies only for Single Page Application (SPA)
-
Show loading
-
Progressive loading. (facebook news feed example) Show mock and load content after.
-
Use AppShell link
-
Use event capturing and reproduce events after load (App shell)
- Load script while user fills fields or read some information
-
No more then 7 connections to the server in the same time.
- Inline images
- Inline js
- Inline css
-
Ordering of loading
- Index.html
<head>
async loading of css/jsdeffer
for js (??)- why we put <script> into end of the index.htm (???)
- http/2 file loading order (???)
-
Parsing js/ First paint (???)
-
Reduce HTTP Requests (time to connect with server)
- DNS resolve(chaching DNS)
- Inline js, html, json
-
Budgeting
-
Images optimization
- JPG 80 vs JPG 100 critical/non critical
- SVG when possible
- FontIcons vs SVG or compile your own (???)
- Custom fonts vs SVG
- Inline base64 vs separated files
- Images Retina (Sprites are dead) (???)
- webp (???)
- Images alternative text with size
<img alt='' width='' height='' />
- Save with optimization (???) photoshop save as
- Desktop app for Windows FileOptimizer
-
Gzip one file VS. many Gzip + many bundles
- brotli
- option on the server
-
Caching files
- ngnix, Apache, IIS
-
Fast delivery
-
Code minification
ng build --prod
-
Lazy loading / Preloading
-
Angular modules (??)
- Example for login page. LoginPageModule without dependencies. UnAutorazedUser.
- Lazy-loading + preloading stratagy (???) (link)[https://medium.com/@adrianfaciu/custom-preloading-strategy-for-angular-modules-b3b5c873681a]
-
Load images that only on the screen
-
-
Analyse files
- web pack bundle anyliser (???)
-
Delivery only what is needed
- Reduce first bundle
- Optimise critical pages
-
Virtual scroll
-
Reduce DOM elements
<ng-container></ng-container>
-
Web workers for highly performance calculations
-
Prefetching
- angular prefetching modules from links (???) example code
-
Angular
(???) Define types of application and provide check lists
-
CRM
- Admin panels
- User panel
-
Mobile application
-
Landing pages
-
E-shop
-
Site builder