-
Notifications
You must be signed in to change notification settings - Fork 6.3k
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
Migrate DownloadComponents
from nodejs.dev
#5303
Comments
It looks like |
@HinataKah0 that makes sense! Can you create an issue to migrate both the |
BTW @HinataKah0 I moved |
|
I think I'll work on I just realised that Since it's very low effort, I have opened a PR. If we feel it's not necessary, feel free to close it. |
Hey guys !
|
Hey, @HinataKah0 and @AugustinMauroy I'm getting worried with the migration of the Download Components, as the current types might not align with the types we have now. I'd like to draw your attention to this: https://github.com/nodejs/nodejs.org/blob/main/layouts/DownloadReleasesLayout.tsx#L19 This is what we use for fetching releases on client-side, and https://github.com/nodejs/nodejs.org/blob/main/layouts/DownloadReleasesLayout.tsx#L28 This is the typing of the object. Please keep these in mind types when doing such PRs (https://github.com/nodejs/nodejs.org/pull/5345/files) to consider that we might have different types with the new Components. My suggestion is to extract this (https://github.com/nodejs/nodejs.org/blob/main/layouts/DownloadReleasesLayout.tsx#L19-L43) into a React Context + Provider (Pretty much to have the data available through the whole App) And make changes on the mapping of the data (https://github.com/nodejs/nodejs.org/blob/main/layouts/DownloadReleasesLayout.tsx#L29-L38) to fit what the migrated Components need. I would go to lengths to say that if we have types already on the Please, feel free to work on this (@HinataKah0 if you have time) and let's hold the current open Download Component PRs until we get this Provider and changes to the types merged so that we can adequately ensure that once we start using the migrated Components, we don't need to go through the hassle of updating/fixing them. |
Noted, let me take a look into it. |
I just checked. Yes, I agree to have a Context + Provider. However, current
And In I think they can share the Like you said, we can have a Context + Provider. So we don't need to do Props Drilling since
I think we can discuss this in a separate issue so we don't pollute this thread since it's specific for components migration. |
No, we should not try to replicate nodejs.dev approach here, we might not even need the release date. If we need, we can use (Check out the main branch to see its usages). The issue is this data is server-side only as Pretty much I want to avoid overcomplexing what we have, and if we can avoid making way too many requests and fetching the schedule.json that'd be great. |
This comment was marked as outdated.
This comment was marked as outdated.
Hi @ovflowd , After I thoroughly studied the usages of
All the fields needed by new UI can be fulfilled by Currently Both Actually I think we have a few options... Option 1: Call both APIs as it is and decouple release schedule and release version Option 2: Create a new JSON file based on
|
We should always support client-side, but given we have SSR now with Next.js, I honestly believe leveraging server-side rendering could be good here.
Big outputs aren't the issue here. Regardless of the approach, the requests will have a "big output" due to their nature. That doesn't mean we cannot leverage other techniques such as:
I'd disagree, we need the information to a certain degree that is available on both. To all contents, we could even build a locally-stored JSON file with the dump of I honestly believe creating a Then we can use SWR to self-consume the JSON file on the client-side and leverage SWR to do the caching on the client-side. Following this approach, we also reduce the strain on Node.js Infrastructure (Node.js Distribution Server) where the So, sadly I'm against both the options you provided. The intent is great, but there are issues, as I mentioned, ranging from over-complexity, unnecessary network calls happening, and strain on the Node.js Infrastructure. Let me know what you think about the approach I've suggested. |
Ah, initially I thought we wanted to offload everything (fetching + merging) to client side. Thus, I was confused on how to utilize Thanks for explaining it thoroughly! About the leveraging server side approach, I am strongly +1 on it.
+1 on this.
Summary so far Build time: Client side: |
Well actually we only need the latest version of each major version. That would already reduce the size by a lot. Could you try that? |
Wdym with this? |
+1 😄
Any comparison with current time check. For example: checking if current state is LTS |
Have you a proxy ? have you set a proxy ? |
nah, that gone automatically but now this
then chatgpt says to delete that module and then try but same error again with other module |
and i think tourbo will not work in my rpi
|
the socket timeout comes ramdomly |
Actually I think you can run without Maybe let's not discuss how to setup locally here, because the issues are usually very specific (don't apply to everyone). |
but its not letting me do anything, when i replace one tool, other one creates problem. i think binaries created with rust code was not created for arm devices so i think i need to use a old version. may be next 12 or 11 something |
please remove my name, i wont be able to contribute because of my hardware |
No worries, @Padmanabh82... We appreciate the effort anyways! You could open an issue on Vercel's Turborepo requesting an ARM binary support in the future! I wonder why they don't provide ARM support if M1/M2 MacBooks/Macs are ARM 🤔 |
I have m1 Ship and everything it's good. |
i was also thinking that, but dont know 😐 and later i also couldn't find the libs for arm SWC |
Yea, really weird. Would def recommend opening an issue on vercel repository :) |
Hey, working on |
Working on |
FYI right now #5365 is a blocker for most of the Components, so let's wait for that to get merged before working on new Components. |
DownloadComponents
and Hero
Component from nodejs.dev
DownloadComponents
from nodejs.dev
Good news! |
FYI DownloadComponents can now be worked on :) |
|
We're closing this issue for the time-being as we're going either to update these issues if needed or create new ones for the development of the new design. |
Continuing the migration of components from
nodejs.dev
that we started here, we should start migrating theDownloadComponents
from thenodejs.dev
repository.This issue will keep track of these components and their development progress.
The Migration of each Component
components/Downloads
folder on this repositorycomponents/Downloads/Banner
)hooks
folder of the repository.Dark Theme Switcher
), if it is straightforward enough (e.g. a dark theme switcher plugin for Next.js or it is simple enough to code by ourselves, e.g. a Hook that we manage together with a React Provider) then feel free to do it.List of Components to Migrate
UpcomingReleases
InstallTabs
@AugustinMauroyuseDetectOs
hooks fromnodejs.dev
#5310 to be done firstDownloadToggle
DownloadReleases
DownloadHeader
@AugustinMauroyDownloadCards
@HinataKah0DownloadAdditional
useDetectOS
@FHachezThe text was updated successfully, but these errors were encountered: