Normally gatsby plugins are listed as dependencies in package.json so npm
handles installing their subdependencies. Since we're using a local plugin we
need to make sure those subdependencies are installed. Otherwise we run into
build problems when our plugin loads and can't find it's dependencies. In our
case we get
Error: Cannot find module 'airtable'
I think the easiest way to handle this is listing the local plugin as a
dependency. That way npm will handle everything for us.
Normally gatsby plugins are listed as dependencies in
package.json
so npm handles installing their subdependencies. Since we're using a local plugin we need to make sure those subdependencies are installed. Otherwise we run into build problems when our plugin loads and can't find it's dependencies. In our case we getI think the easiest way to handle this is listing the local plugin as a dependency. That way npm will handle everything for us.