dzcode.io icon indicating copy to clipboard operation
dzcode.io copied to clipboard

Perf: Improve initial page load experience

Open Fcmam5 opened this issue 4 years ago • 2 comments

Describe the bug

As a user/crawler, I should see minimal content when pages are loading. And ideally, the page loads faster for me.

To Reproduce Steps to reproduce the behavior:

  1. Empty cache and access to any page

Expected behavior

  • See "something" while the page is loading.
  • Load the main/important content at first, instead of none or everything

Screenshots

Google lighthouse score might also confirm this issue:

image

Possible solutions

  • Prioritize content loading over unnecessary assets that can be lazy-loaded (for example article content over GH contributors)
  • Dynamically render components
  • Cache Backend-to-data source requests/queries
  • Consider SSR
  • Do more work on the backend (for example fetching contributors lists and returning their avatars).

Fcmam5 avatar May 23 '21 13:05 Fcmam5

thanks for the feedback @Fcmam5 i'm converting this issue into a task, i will add a checklists section at the bottom, so that we can apply this suggestions progressively, and add more suggestions on our way

ZibanPirate avatar May 23 '21 15:05 ZibanPirate

or better, i will create a feature branch and link it this issue.

please see #307 for more information on the progress

ZibanPirate avatar May 23 '21 15:05 ZibanPirate