Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

137
Visualizações
Content is not being updated after revalidate time in Nextjs

I have a blog created with Nextjs and hosted on Vercel where I'm using Incremental Static Regeneration. I set the revalidate time to 60 seconds but when I update something in the database, If i'm not wrong after a request when revalidate time pass it should start rebuilding the page in the background so on the next requests the page would be updated, but that does not happen, even if I wait 10 minutes the content keep being the old, it does not look like a rebuild is happening at all, this is the code I am using on the mentioned page

export const getStaticProps: GetStaticProps = async ({ params }) => {

  const { id } = params;

  const result = await getPost(id?.toString()!);
  const parsed = await parseMarkdown(result.content);
  return {
    props: {
      post: result,
      md: parsed,
    },
    revalidate: 60,
  };
};

export const getStaticPaths: GetStaticPaths = async () => {
  const result = await getAllPosts();
  const paths = result.data.map((post) => {
    return {
      params: { id: post.id },
    };
  });
  return {
    paths,
    fallback: "blocking",
  };
};

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda