A place for non-profits to configure stock music made by artists from Akron, OH.
- Built with GatsbyJS v2.19 (CLI v2.10)
- Server-side functionality written in NodeJS v12.11.1
- UI Components made with ReactJS v16.13
- CMS is Contentful
- Data requests made using GraphQL
- CI/CD and hosting through Netlify
- Monitoring through Google Analytics
This site requires a .env
file with the following properties:
accessToken
spaceId
trackingId
The spaceID
and accessToken
are from Contentful.
The trackingId
is from Google Analytics
You'll also need to add these three environment variables in Netlify by going to Setting > Build & Deploy > Environment.
npm i
- Install your dependencies
Then Either
gatsby develop
- Build the assets in development mode and start a web server
Or (Hopefully before you commit!)
gatsby build
- Build the assets in production mode
gatsby serve
- Serve the assets in production mode
Lol
- Follow this guide to connect Netlify and GitHub and deploy the site
- Enable Netlify forms through their UI
-
Since Gatsby pre-runs all of your GraphQL queries when the site is built, you'll need to re-deploy when content changes are made in Contetful unless you follow this guide on setting up a build hook that Contentful can kick off on publish.
-
Static pages for each blog in Contentful are built in the
gatsby-node.js
file using the./template/genre.js
file as a template and using thename
property from Contentful as the URL slug. -
When you update your Node version (and maybe other times?) you'll need to use the "Clear Cache And Deploy" in Netlify instead of the regular deploy trigger.
You'll need to set the content model up in Contenful to ensure your GraphQL queries will work. Contact me and I'll ship the model over.