jannikbuschke / gatsby-antd-docs

A gatsby starter for a technical documentation website
https://www.jannikbuschke.de/gatsby-antd-docs/
MIT License
68 stars 21 forks source link

GraphQL errors on `yarn start` #13

Closed AlanFoster closed 4 years ago

AlanFoster commented 4 years ago

Thanks for the template! I was having some issues getting it running. I used the following:

npx gatsby new gatsby-antd-docs https://github.com/jannikbuschke/gatsby-antd-docs
cd gatsby-antd-docs
yarn start

Which to a stream of errors in the Gatsby log, one of which being:

The GraphQL query from /Users/user/Documents/code/gatsby-antd-docs/src/templates/template.tsx failed.

Errors:
  [BABEL] unknown: Invalid Option: The 'modules' option must be one of
   - 'false' to indicate no module processing
   - a specific module type: 'commonjs', 'amd', 'umd', 'systemjs' - 'auto' (default) which will automatically select 'false' if the current
     process is known to support ES module syntax, or "commonjs" otherwise
   (While processing: "base$1")

  GraphQL request:10:5
   9 |     }
  10 |     body
     |     ^
  11 |   }
URL path:
  /docs/guide/anchor
Context:
  {
    "id": "18268041-f640-5ff2-a799-83aae68223fe"
  }
Plugin:
  none
Query:
  query BlogPostQuery(
    $id: String
  ) {
    mdx(id: {eq: $id}) {
      id
      frontmatter {
        title
        root
      }
      body
    }
  }

And when visiting localhost:8000 in the browser and navigating to pages, I also see:

image

jannikbuschke commented 4 years ago

hi @AlanFoster ,

Thanks for bringing this up. I dont use yarn, but I tested the docs https://github.com/jannikbuschke/gatsby-antd-docs#getting-started again and it seems to work.

I also updated some dependencies, so maybe your issue is already resolved? Can you try again?

In case this is a yarn issue, I wont be able to help.

AlanFoster commented 4 years ago

Thanks! Everything's working now after trying again with the latest changes :+1: