Skip to content

Latest commit

 

History

History
29 lines (25 loc) · 821 Bytes

README.md

File metadata and controls

29 lines (25 loc) · 821 Bytes

Gatsby Firebase Source for gatsby v3

install via NPM

npm i gatsby-source-firebase-v3

add plugin to gatsby-config with options:

{
  // point to the firebase private key downloaded
  credential: require("./firebase-service-account.json"),
  // your firebase database root url
  databaseURL: "https://<DATABASE_NAME>.<REGION>.firebasedatabase.app/",
  types:[
    {
      type: "Product",  // this will be allProduct in GraphQL query
      path: "products", // reference
    // optional
      query: ref => ref.limitToLast(10), 
      node: (node)=> node
    }
  ]
}

donate eth 💸 0x14e0e2b13814526797b6f10676d69498bcd9b411

eth address