Skip to content

Gatsby source plugin for pulling data into Gatsby from Contenta CMS (Drupal distro).

Notifications You must be signed in to change notification settings

tarekdj/gatsby-source-contenta

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gatsby-source-contenta

Source plugin for pulling data into Gatsby from Contenta CMS (Drupal distro).

Pulls data from Drupal sites with the Contenta CMS distro installed.

An example site for using this plugin is at TBD

Status

This module is at prototype-level based on gastby-drupal-source. It currently only pulls from Contenta CMS recipes and images. TODOs include making it work with other entites.

Install

npm install --save gatsby-source-contenta

How to use

// In your gatsby-config.js
plugins: [
  {
    resolve: `gatsby-source-contenta`,
    options: {
      baseUrl: `http://url.to.your.contenta.site`,
    },
  },
]

How to query

You can query recipes created from Contenta CMS like the following:

{
  allDrupalRecipes(sort: { fields: [created], order: DESC }, limit: 10) {
    edges {
      node {
        title
        id
        createdAt(formatString: "DD-MMM-YYYY")
        image {
          url
        }
      }
    }
  }
}

About

Gatsby source plugin for pulling data into Gatsby from Contenta CMS (Drupal distro).

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published