3 ms·
I like idlewords' advice and I'd follow it for websites, but for web apps if there is a point where you can split the code then it is faster to load in stages.
by onion2k 6y ago
I like idlewords' advice and I'd follow it for websites, but for web apps if there is a point where you can split the code then it is faster to load in stages. For example, in the app I work on when you first load the page it shows you a login form. While you're filling that in your browser is busy prefetching some assets (components, styles, icons) you'll need after you've logged in. It reduces the waiting time when you're using the app by a few seconds.
(To answer the obvious 'what a waste if the user fails to log in!' criticism, that's fewer than 0.2% of log in attempts. Most people benefit.)