Giter VIP home page Giter VIP logo

soundandsilence's Introduction

Logo

Gatsby WordPress Starter

A starter skeleton that leveraged the WordPress API for Gatsby.

This Project was forked from Gatsby Advanced Starter

Features

Logo

New Features

  • WordPress plugin for Gatsby
  • Configured to work with WordPress Advanced Custom Fields
  • Auto generated Navigation for your Wordpress Pages
  • Minimal UI and Styling -- highly customizable
  • Styled Components

Plus these features from Gatsby Advanced Starter,

  • Blazing fast loading times thanks to pre-rendered HTML and automatic chunk loading of JS files
  • Separate components for everything
  • High configurability:
    • User information
    • User social profiles
    • Copyright information
    • More!
  • Author segment
    • Name
    • Location
    • Description
    • Links
    • Follow Me button
  • Posts in Markdown
    • Code syntax highlighting
    • Embed YouTube videos
    • Embed Tweets
  • Tags
    • Separate page for posts under each tag
  • Categories
    • Separate page for posts under each category
  • Disqus support
    • Notifications about new disqus comments
  • Google Analytics support
  • NPM scripts for GitHub Pages deployment
  • Social features
    • Twitter tweet button
    • Facebook share/share count
    • Reddit share/share count
    • Google+ share button
    • LinkedIn share button
    • Telegram share button
  • SEO
    • Sitemap generation
    • robots.txt
    • General description tags
    • Schema.org JSONLD (Google Rich Snippets)
    • OpenGraph Tags (Facebook/Google+/Pinterest)
    • Twitter Tags (Twitter Cards)
  • RSS feeds
  • Loading progress for slow networks
  • Offline support
  • Web App Manifest support
  • Development tools
    • ESLint for linting
    • Prettier for code style
    • Remark-Lint for linting Markdown
    • write-good for linting English prose
    • gh-pages for deploying to GitHub pages
    • CodeClimate configuration file and badge

Logo

Instructions:

Using this starter requires:

  • A Wordpress acct.
  • Configuring the gatsby-node file. You really only need to change BaseUrl, and hostingWPCOM if you're using WP.com rather than WP.org
{
  resolve: 'gatsby-source-wordpress',
  options: {
    // The base url to your WP site.
    baseUrl: 'YOUR_WORDPRESS_URL',
    // WP.com sites set to true, WP.org set to false
    hostingWPCOM: false,
    // The protocol. This can be http or https.
    protocol: 'http',
    // Use 'Advanced Custom Fields' Wordpress plugin
    useACF: true,
    auth: {},
    // Set to true to debug endpoints on 'gatsby build'
    verboseOutput: false
  }
},
  • Update GraphQL queries to match your WordPress Content. This is the query currently on the index page. You either need to add ACF's in your WordPress to match the query (in this case Project and Date), or you need to remove those aspects of the query. The featured_media isn't a problem -- it'll work even if you have posts without featured images.
allWordpressPost {
      edges {
        node {
          featured_media {
            source_url
          }
          author {
            name
            avatar_urls {
              wordpress_24
              wordpress_48
              wordpress_96
            }
          }
          date
          slug
          title
          modified
          excerpt
          id
          acf {
            project
            date
          }
          categories {
            name
          }
          tags {
            name
          }
          content
        }
      }
    }
  • Finally, you'll probably want to update the SiteConfig to match your info, becuase right now it has mine. ๐Ÿค 
  • Suggestions:
    • Use the Prism WP Plugin to pass code blocks down.
    • If you give an ACF to a single post, you must give it to EVERY post, or GraphQL gets confused.

Notes

Ruben Harutyunyan did most of the hard work with Gatsby Advanced Starter. The rest of the credit is due to Gatsby.

WARNING: Make sure to edit static/robots.txt to include your domain for the sitemap!

soundandsilence's People

Contributors

braveliltoaster avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.