vercel / reactions

Next.js Incremental Static Regeneration Demo
https://reactions-demo.vercel.app
MIT License
308 stars 43 forks source link

Add Your Reaction Here #1

Open chibicode opened 4 years ago

chibicode commented 4 years ago

Reactions on this comment will be reflected on https://reactions-demo.vercel.app/

This uses Next.js’s Incremental Static Regeneration feature which is supported out of the box by Vercel’s Edge Network.

chibicode commented 4 years ago

Data Fetching Code:

https://github.com/chibicode/reactions/blob/42e08310fdbdd370a366bc6cacd043e2636c10c6/pages/index.js#L3-L60

martinseanhunt commented 4 years ago

This is so cool!

anteeek commented 4 years ago

Damn.

Nases commented 4 years ago

Exactly what I needed, thanks!

amir-gorji commented 3 years ago

Are you sure its revalidation is done every 1 second or the Github gets updated values after a delay? I get the updated values on the page after a couple of minutes.

pungggi commented 3 years ago

Interstingly it updated the first time after a second and a second time after some minutes..

msreekm commented 3 years ago

page is not refreshing after1 sec! updated only after few mins..

nghiepnguyen520 commented 3 years ago

page is not refreshing after1 sec! updated only after few mins..

yes, I tested and same issue with you

mdovn commented 3 years ago

So the first request that trigger the incremental build will alway get the stale data?

thisisbintang commented 3 years ago

It's fast and absolutely static.

Abdalhadi-Jarad commented 3 years ago

Is it expected to be updated alone every 1 second without refreshing ? Because I wait 20 Minutes just watching if it will update the information and still not updating

abzr1 commented 3 years ago

@Abdalhadi-Jarad no, since it's a static page you have a refresh a couple of times to regenerate the page.

jrayo commented 3 years ago

Just in case anyone wants to know how this demo behaves with different timeouts, I made a fork and you can see it on https://reactions.jrayo.vercel.app/

zhangfaliang commented 3 years ago

Is it expected to be updated alone every 1 second without refreshing ? Because I wait 20 Minutes just watching if it will update the information and still not updating

abzr1 commented 3 years ago

@zhangfaliang no, since it's a static page you have a refresh a couple of times to regenerate the page.

coderinblack08 commented 3 years ago

this has got to be a record :D

Slipromise commented 3 years ago

hello github

javakian commented 3 years ago

hello, hello, yes i think so

zed-b commented 3 years ago

Great, but I am a little bit confused, doesn't this feature just beg for custom bots to poll the static sites periodically, since the first page served after timeout is stale?

abzr1 commented 3 years ago

Great, but I am a little bit confused, doesn't this feature just beg for custom bots to poll the static sites periodically, since the first page served after timeout is stale?

@zed-b the page served whilst the timeout is stale displayed a loading or skeleton or blank page whilst the new page is being regenerated.

mkotsollaris commented 2 years ago

@chibicode @leerob I think I am missing something. I modified the code (see gist) to print out a given timestamp passed through getStaticProps. I would expect that the page should regenerate every minute, and hence my timestamp shouldn't change during refresh. However, I noticed that when I refresh the page, the timestamp is always updated. thoughts? 🤔

Update: I just realized that during yarn dev getStaticPropstriggers all the time during refresh, but when running fromyarn start`, getStaticProps behaves as it should!

GBR-422777 commented 1 year ago
Screenshot 2022-11-25 at 9 22 44 AM

Screenshot 2022-11-25 at 9 23 07 AM

Screenshot 2022-11-25 at 9 23 23 AM
JoshuaR503 commented 1 year ago

Screen Shot 2023-01-05 at 12 00 16 PM Screen Shot 2023-01-05 at 12 00 32 PM

Does anybody know why my reactions are not up to date? I visited the demo app a while ago and it worked. Yesterday I visited it again and noticed the values have not changed since then.

Levent0z commented 1 year ago

Still not fixed.

CleanShot 2023-01-18 at 21 20 43@2x
leerob commented 1 year ago

Our GitHub personal access token expired. We'll get a new one added. In the meantime, you can see a similar demo here: https://on-demand-isr.vercel.app/

relaxedleaf commented 1 year ago

Hi, do we have updates on renewing the GitHub personal access token?

mnm1984 commented 1 year ago

hi

htrigoso commented 1 year ago

raa

pauloalmeida19 commented 1 year ago

sdasdasdasdasdsada

Peter-developer01 commented 1 year ago

Really? Why it is STILL not worked?

o-az commented 11 months ago

RIP

aleczratiu commented 9 months ago

Ok, the

Our GitHub personal access token expired. We'll get a new one added. In the meantime, you can see a similar demo here: https://on-demand-isr.vercel.app/

Seems that the star number increased, this one is working thanks

sabeerbikba commented 1 month ago

Screen Shot 2023-01-05 at 12 00 16 PM Screen Shot 2023-01-05 at 12 00 32 PM

Does anybody know why my reactions are not up to date? I visited the demo app a while ago and it worked. Yesterday I visited it again and noticed the values have not changed since then.

Looks like api cached

leerob commented 1 month ago

FYI: We have an up-to-date demo here https://on-demand-isr.vercel.app/