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

performance: get last edit/deploy locale timestamp for layouts on build time #13153

Merged
merged 48 commits into from
Jun 13, 2024

Conversation

nhsz
Copy link
Member

@nhsz nhsz commented Jun 12, 2024

This PR updates how getLocaleTimestamp is used across layouts and pages, to calculate the new lastEditLocaleTimestamp & lastDeployLocaleTimestamp values on build time instead of executing this logic on runtime, and updates the corresponding components, interfaces and types to use them properly.

Description

  • pages
    • updates src/pages/[...slug].tsx
    • updates src/pages/_app.tsx
    • updates src/pages/assets.tsx
    • updates src/pages/bug-bounty.tsx
    • updates src/pages/community.tsx
    • updates src/pages/contributing/translation-program/acknowledgements.tsx
    • updates src/pages/contributing/translation-program/contributors.tsx
    • updates src/pages/dapps.tsx
    • updates src/pages/developers/index.tsx
    • updates src/pages/developers/learning-tools.tsx
    • updates src/pages/developers/local-environment.tsx
    • updates src/pages/developers/tutorials.tsx
    • updates src/pages/eth.tsx
    • updates src/pages/gas.tsx
    • updates src/pages/get-eth.tsx
    • updates src/pages/index.tsx
    • updates src/pages/index.tsx
    • updates src/pages/layer-2.tsx
    • updates src/pages/learn.tsx
    • updates src/pages/learn.tsx
    • updates src/pages/quizzes.tsx
    • updates src/pages/roadmap/vision.tsx
    • updates src/pages/roadmap/vision.tsx
    • updates src/pages/run-a-node.tsx
    • updates src/pages/stablecoins.tsx
    • updates src/pages/staking/deposit-contract.tsx
    • updates src/pages/staking/index.tsx
    • updates src/pages/wallets/find-wallet.tsx
    • updates src/pages/wallets/index.tsx
    • updates src/pages/what-is-ethereum.tsx
  • components
    • updates src/components/FileContributors.tsx (uses lastEditLocaleTimestamp)
    • updates src/components/Footer.tsx (uses lastDeployLocaleTimestamp)
  • layouts
    • updates src/layouts/Docs.tsx
    • updates src/layouts/Roadmap.tsx
    • updates src/layouts/RootLayout.tsx
    • updates src/layouts/Static.tsx
    • updates src/layouts/Tutorial.tsx
    • updates src/layouts/Upgrade.tsx
  • interfaces
    • updates MdPageContent
  • types
    • updates Root
    • updates BasePageProps
  • removes lastUpdatedDate & lastDeployDate page props

@nhsz nhsz self-assigned this Jun 12, 2024
@github-actions github-actions bot added the tooling 🔧 Changes related to tooling of the project label Jun 12, 2024
Copy link

netlify bot commented Jun 12, 2024

Deploy Preview for ethereumorg ready!

Name Link
🔨 Latest commit 711019d
🔍 Latest deploy log https://app.netlify.com/sites/ethereumorg/deploys/666a147a3628680008e6639b
😎 Deploy Preview https://deploy-preview-13153--ethereumorg.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
7 paths audited
Performance: 46 (🟢 up 8 from production)
Accessibility: 92 (no change from production)
Best Practices: 88 (🔴 down 4 from production)
SEO: 93 (no change from production)
PWA: -
View the detailed breakdown and full score reports

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

@nhsz nhsz added epic 💪 This issue is an epic on our product roadmap roadmap 🛣️ Relate to ethereum.org website roadmap needs dev approval 🧑‍💻 Approval from a developer is needed before merging labels Jun 12, 2024
Copy link
Member

@wackerow wackerow left a comment

Choose a reason for hiding this comment

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

Looks good, nice job @nhsz! Just a stray comment I assume we don't want anymore

src/pages/_app.tsx Outdated Show resolved Hide resolved
@nhsz nhsz requested a review from wackerow June 12, 2024 20:54
Copy link
Member

@pettinarip pettinarip left a comment

Choose a reason for hiding this comment

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

LGTM! nice job @nhsz

@pettinarip pettinarip merged commit 4560e3a into dev Jun 13, 2024
10 checks passed
@pettinarip pettinarip deleted the performance-locale-timestamp branch June 13, 2024 10:21
This was referenced Jun 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
epic 💪 This issue is an epic on our product roadmap needs dev approval 🧑‍💻 Approval from a developer is needed before merging roadmap 🛣️ Relate to ethereum.org website roadmap tooling 🔧 Changes related to tooling of the project
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants