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

[FEATURE] Request and display SurPathHub blog post section #141

Open
1 task done
mkubdev opened this issue Oct 19, 2022 · 3 comments
Open
1 task done

[FEATURE] Request and display SurPathHub blog post section #141

mkubdev opened this issue Oct 19, 2022 · 3 comments
Labels
enhancement New feature or request

Comments

@mkubdev
Copy link
Contributor

mkubdev commented Oct 19, 2022

Detailed description

The blog is displaying mocked blog posts 👇

image

We need to implement data fetching from Dev.to and display the real blog posts from the community.

Context

Because we need to update mocked content from the Figma/Next.js migration.

Possible implementation

Use getStaticProps as data fetching strategy.

export const getStaticProps = async () => {
  const res = await fetch("https://dev.to/api/articles?username=surpathhub");
  const data = await res.json();

  return {
    props: {
      data,
    },
  };
};

@vinzvinci Do you already have account for SurPath Hub?

Additional information

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@mkubdev mkubdev added the enhancement New feature or request label Oct 19, 2022
@mkubdev mkubdev changed the title [FEATURE] Request and display SurPath blog post [FEATURE] Request and display SurPathHub blog post section Oct 19, 2022
@vinzvinci
Copy link
Member

Yes

https://dev.to/surpathhub

@mkubdev
Copy link
Contributor Author

mkubdev commented Oct 19, 2022

Yes

https://dev.to/surpathhub

Ok so it's normal that https://dev.to/api/articles?username=surpathhub is empty.

@vinzvinci
Copy link
Member

yeah let's put on-hold first xD

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants