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

Add logging to revalidate api #2490

Merged
merged 1 commit into from
Jun 24, 2024

Conversation

RubenSandwich
Copy link
Collaborator

@RubenSandwich RubenSandwich commented Jun 21, 2024

πŸ”— Relevant links

  • Preview link - None test locally πŸ”Ž
  • Asana task - None chore task 🎟️

πŸ—’οΈ What

Changes the revalidate api so that a list of paths that either successfully or failed to revalidated are returned, e.g.

[
  {
    "status": "fulfilled",
    "value": "/packer/docs/templates/hcl_templates/functions/string/trim"
  },
  {
    "status": "fulfilled",
    "value": "/packer/docs/templates/hcl_templates/functions/string/trimprefix"
  },
]

πŸ§ͺ Testing

  1. checkout this branch locally and start up the project
  2. hit the revalidate api
    (Make sure you have jq installed)
curl -X POST "http://localhost:3000/api/revalidate" \
     -H "Content-Type: application/json" \
     -d '{"product": "packer"}' | jq .
  1. json of either successfully or failed to revalidated paths should be returned

Copy link

vercel bot commented Jun 21, 2024

The latest updates on your projects. Learn more about Vercel for Git β†—οΈŽ

Name Status Preview Comments Updated (UTC)
dev-portal βœ… Ready (Inspect) Visit Preview πŸ’¬ Add feedback Jun 21, 2024 7:06pm

Copy link

πŸ“¦ Next.js Bundle Analysis

This analysis was generated by the next.js bundle analysis action πŸ€–

This PR introduced no changes to the javascript bundle πŸ™Œ

@RubenSandwich RubenSandwich merged commit dfc7d73 into main Jun 24, 2024
9 checks passed
@RubenSandwich RubenSandwich deleted the rn.chore.add-logging-to-revalidate-api branch June 24, 2024 12:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants