Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

gatsby-source-storyblok

Package Overview
Dependencies
Maintainers
1
Versions
85
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

gatsby-source-storyblok

Gatsby source plugin for building websites using the Storyblok headless CMS as a data source.

  • 0.1.2
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
4.3K
decreased by-6.7%
Maintainers
1
Weekly downloads
 
Created
Source

Introduction

This is a Gatsby source plugin for building websites using the Storyblok headless CMS with true visual preview as a data source.

How to install

npm install --save gatsby-source-storyblok

How to use?

module.exports = {
  plugins: [
    {
      resolve: 'gatsby-source-storyblok',
      options: {
        accessToken: 'YOUR_TOKEN',
        homeSlug: 'home',
        version: 'draft',
        timeout: 5000 // only needed if you want to increase the request timeout - default is 5000
      }
    }
  ]
}

How to query?

All Content Entries

{
  allStoryblokEntry {
    edges {
      node {
        id
        name
        created_at
        published_at
        uuid
        slug
        full_slug
        content
        is_startpage
        parent_id
        group_id
      }
    }
  }
}

A Single Content Entry

{
  StoryblokEntry {
    edges {
      node {
        id
        name
        created_at
        published_at
        uuid
        slug
        full_slug
        content
        is_startpage
        parent_id
        group_id
      }
    }
  }
}

Datasource Entries

To be able to query data sources, the plugin needs to know which ones to load. You need to specify the data sources to load through the config like this:

{
  resolve: 'gatsby-source-storyblok',
  options: {
    dataSources: ['data-source-1', 'data-source-2', 'data-source-3'],
    // ... more config
  }
},

Then you can use following GraphQL query:

allStoryblokDataSourceEntry {
  edges {
    node {
      id
      name
      value
      data_source
    }
  }
}

Keywords

FAQs

Package last updated on 21 Sep 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc