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

feat(clock): add Doomsday clock #180

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft

Conversation

angrybacon
Copy link
Owner

@angrybacon angrybacon commented Aug 5, 2022

This MR to save my progress on #36. Mostly a proof of concept for when the sharing issue described below is solved. When/if it does get solved, the idea is to have the current -- as per thebulletin.org -- Doomsday clock on the Wiki behind Konami.

Next.js does not yet support a way to reuse asynchronous data across multiple pages (see vercel/next.js#10949). The workaround is to rely on getStaticProps from _app.tsx and the caveat is that the data will be queried for every page built. Several ways exist to mitigate the issue, all imperfect:

  • Cache the data using the pipeline memory through promise cookies like this MR currently proposes (see src/tools/clock/getClockCached.ts for the limitations)
  • Cache the data using a file: requires running a secondary Node instance to read and write the file
  • Run a fetching script before the Next.js build: requires a more customizable pipeline: currently not supported by Netlify's free plan
  • Cache the data using a server. See scryfall/server.js

@angrybacon angrybacon added the Enhancement New feature or request label Aug 5, 2022
@angrybacon angrybacon self-assigned this Aug 5, 2022
@angrybacon angrybacon changed the title feat(clock): scrap thebulletin.org and retrieve the Doomsday clock feat(clock): add Doomsday clock Aug 5, 2022
@angrybacon angrybacon marked this pull request as draft August 5, 2022 14:06
@angrybacon angrybacon force-pushed the feat--doomsday-clock branch from 9eb6ffa to 09c5ffc Compare August 5, 2022 15:26
Repository owner deleted a comment from netlify bot May 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant