1.0.2 • Published 4 years ago

gatsby-source-hashnode-api v1.0.2

Weekly downloads
-
License
0BSD
Repository
github
Last release
4 years ago

Description

A Gatsby Plugin to fetch data from Hashnode API to display it on your gatsby site.

Note: gatsby-source-hashnode does the same thing except it does not convert the images in the appropriate format that Gatsby expects. This plugin solves that.

How to install

npm i gatsby-source-hashnode-api

Examples of usage

In the gatsby-config.js, append this plugin in plugins array.

plugins: [
    'gatsby-source-hashnode-api',
    "gatsby-plugin-image",
    ...
]

How to query for data

After installing, open the graphql explorer. Paste the following code in editor and fire the query.

query MyQuery {
  allHashnodePost {
    nodes {
      brief
      title
      slug
      cuid
      coverImage {
        id
      }
    }
  }
}
1.0.3

4 years ago

1.0.2

4 years ago