showing results for - "getinitialprops on phone not working"
Lena
09 May 2016
1//Try not use axios if you're using it.
2//if not try use exactly this syntax
3export async function getStaticProps() {
4  const res = await fetch(`http://localhost:3000/api/blogs`)
5  const Blogs = await res.json()
6  return {
7    props: {
8      Blogs,
9    },
10  }
11}