Understanding Gatsby plugins
By this stage in this book, you should have all the tools you need to get a Gatsby site into production. In this chapter, we are going to go one step further and talk about creating reusability across multiple Gatsby sites using something called Gatsby plugins. Gatsby plugins are node packages that abstract common site functionality that utilizes Gatsby APIs. By bundling functionality into a plugin, you can source data, create pages, implement SEO, and so much more with just a few lines. Gatsby plugins also act as a way to modularize larger sites into more manageable chunks of functionality.
The two most common types of plugins are as follows:
- Gatsby Source Plugins: Source plugins allow you to gather data from a data source and ingest it into Gatsby's GraphQL data layer. You could source data from anywhere, such as APIs, RSS feeds, or CMSes, as we did in Chapter 3, Sourcing and Querying Data (from Anywhere!). Once data has been ingested...