/react-graphql-blog

A React Blog Powered by the Cosmic JS GraphQL API

Primary LanguageJavaScript

React GraphQL Blog

React GraphQL Blog

This is an example of a simple blog app built using create-react-app. It's powered by GraphQL connected to the Cosmic JS API for easy content management.

Getting Started

  1. Go to Cosmic JS and create a new Bucket.
  2. Import the bucket.json in this repo to your Bucket located in Your Bucket > Import / Export
  3. Download the app:
git clone https://github.com/cosmicjs/react-graphql-blog
cd react-graphql-blog
yarn

Starting the app

Run in development

Connect to your Cosmic JS Bucket using the environment variable COSMIC_BUCKET or edit the config.js file.

COSMIC_BUCKET=your-bucket-slug yarn start

Build for production

COSMIC_BUCKET=your-bucket-slug yarn build