You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What do we need to build or fix?
We need to implement the logic to connect our single blog post UI with dev.to. This involves automatically pulling content data from dev.to and ensuring users are directed to the corresponding single post page on our Next.js website instead of being redirected to dev.to. This will help keep users on our website longer.
Technical details 1. Set Up API Call to dev.to:
Extend the getStaticProps function in pages/blog/posts/[id].js to fetch detailed post content from dev.to using their API.
Use the dev.to API to fetch the content for individual blog posts based on their id.
2. Update Single Blog Post UI:
Utilize the fetched data in the BlogPostContainer component.
Pass the necessary data (title, content, author, etc.) to the BlogPostContainer and PostContent.
3. Routing Logic:
Ensure that clicking on a blog post link in the blog post list routes to the new single blog post page using dynamic routing.
Update BlogPostsContainer to link to the new [id].js page.
mariana-caldas
changed the title
Implement Logic to Connect Single Blog Post UI with dev.to and Route Users to Corresponding Page on Next.js Website
Connect Single Blog Post UI with dev.to and route users to corresponding single blog post page
Jun 13, 2024
What do we need to build or fix?
We need to implement the logic to connect our single blog post UI with dev.to. This involves automatically pulling content data from dev.to and ensuring users are directed to the corresponding single post page on our Next.js website instead of being redirected to dev.to. This will help keep users on our website longer.
Technical details
1. Set Up API Call to dev.to:
getStaticProps
function inpages/blog/posts/[id].js
to fetch detailed post content from dev.to using their API.2. Update Single Blog Post UI:
3. Routing Logic:
Approach suggestions
pages/blog/posts/[id].js
Deadline
Please keep in mind that once you assign this task to yourself, you'll need to complete it in 15 days.
Acceptance criteria
yarn build
locally to solve the issues and commit the changes.The text was updated successfully, but these errors were encountered: