Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf: improve drop first load speed #10379

Merged
merged 4 commits into from
Jun 4, 2024
Merged

Conversation

hassnian
Copy link
Contributor

@hassnian hassnian commented Jun 3, 2024

PR Type

  • Bugfix
  • Feature
  • Refactoring

Context

  • fetching the drop a little before inside the setup

  • made some components lazy

  • drop gallery item is loaded once the divider is seen

  • Ref All Drops are very slow #10307

Needs QA check

  • @kodadot/qa-guild please review

Did your issue had any of the "$" label on it?

  • Fill up your DOT address: Payout

Screenshot 📸

  • My fix has changed something on UI;

Copy link

netlify bot commented Jun 3, 2024

Deploy Preview for koda-canary ready!

Name Link
🔨 Latest commit f1ca0eb
🔍 Latest deploy log https://app.netlify.com/sites/koda-canary/deploys/665ee3dcf2bdb5000836e33d
😎 Deploy Preview https://deploy-preview-10379--koda-canary.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@hassnian hassnian marked this pull request as ready for review June 3, 2024 13:00
@hassnian hassnian requested a review from a team as a code owner June 3, 2024 13:00
@hassnian hassnian requested review from preschian and Jarsen136 and removed request for a team June 3, 2024 13:00
Copy link
Contributor

@Jarsen136 Jarsen136 left a comment

Choose a reason for hiding this comment

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

You have applied the similar logic of lazy load in two places. How about making a common lazy wrapper component?

<div>
  <div ref="target"></div>
  <template v-if="targetIsVisible">
      <slot />
   </template>
<div>

const target = ref<HTMLHtmlElement>()
const targetIsVisible = useOnceIsVisible(target)

drop gallery item is loaded once the divider is seen

In case of one day we removed the divider line on the drop page.

@hassnian
Copy link
Contributor Author

hassnian commented Jun 4, 2024

You have applied the similar logic of lazy load in two places. How about making a common lazy wrapper component?

done

Copy link

codeclimate bot commented Jun 4, 2024

Code Climate has analyzed commit f1ca0eb and detected 0 issues on this pull request.

View more on Code Climate.

Copy link

sonarcloud bot commented Jun 4, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

Copy link
Member

@preschian preschian left a comment

Choose a reason for hiding this comment

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

quite really difficult to see the differences. but, lets go

@prury prury added this pull request to the merge queue Jun 4, 2024
Merged via the queue into kodadot:main with commit 1f5e614 Jun 4, 2024
19 checks passed
@prury prury deleted the issue-10307 branch June 4, 2024 17:36
@vikiival vikiival mentioned this pull request Jun 12, 2024
This was referenced Jun 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants