The main Gatsby site at gatsbyjs.org
Run locally with:
yarn install
npm run develop
See the full contributing instructions at https://www.gatsbyjs.org/contributing/how-to-contribute/.
To work with environment variables create a file in the root of www
called .env.development
.
The .env.development
file is ignored by git. Your token should never be committed.
To develop on the starter library, you'll need to supply a GitHub personal access token.
- Create a personal access token in your GitHub Developer settings.
- In the new token's settings, grant that token the "public_repo" scope.
- Add the GitHub token to the
.env.development
file:
GITHUB_API_TOKEN=YOUR_TOKEN_HERE
Several areas of the site include feedback widgets (currently starter library and plugin library). These aren't configured to work in development, unless you have set the public keys (as environment variables) for each widget.
If you have access to the keys, add them like so:
GATSBY_FEEDBACK_KEY_PLUGINLIB=ADD_KEY
GATSBY_FEEDBACK_KEY_STARTERLIB=ADD_KEY
If there's a problem with the feedback widgets, please open an issue in the repo.
If you are not working on starter or site showcase, it might be beneficial to use a placeholder image instead of actual screenshots. It will skip downloading screenshots and generating responsive images for all screenshots and replace them with a placeholder image.
Add the following env variable to your .env.development
file to enable placeholder behaviour:
GATSBY_SCREENSHOT_PLACEHOLDER=true
For more information checkout gatsby-transformer-screenshot
docs.