Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create deploy-gatsby.md #1480

Merged
merged 9 commits into from Jul 12, 2017
Merged

Create deploy-gatsby.md #1480

merged 9 commits into from Jul 12, 2017

Conversation

couturecraigj
Copy link
Contributor

So I wrote something up for deploying gatsby. If you want to take a look and make suggestions on other sections or changes let me know. I will get it written up. Any other issues or bugs that we should inform people about would be helpful too.

@gatsbybot
Copy link
Collaborator

gatsbybot commented Jul 12, 2017

Deploy preview ready!

Built with commit 20587b4

https://deploy-preview-1480--using-drupal.netlify.com

@gatsbybot
Copy link
Collaborator

gatsbybot commented Jul 12, 2017

Deploy preview ready!

Built with commit 20587b4

https://deploy-preview-1480--gatsbygram.netlify.com

@gatsbybot
Copy link
Collaborator

gatsbybot commented Jul 12, 2017

Deploy preview ready!

Built with commit 20587b4

https://deploy-preview-1480--gatsbyjs.netlify.com

Copy link
Contributor

@KyleAMathews KyleAMathews left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good!

deploy-gatsby.md Outdated
## Best Practice


Though you can deploy from the same location multiple times it is recommended that you clear your public directory before each build
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not the recommended practice actually. The only thing that needs deleted between builds is html files of pages that don't exist anymore.

You actually want to keep old builds around because when deploying often, people with your site open can still pull JS/Assets from their particular version of your site.

deploy-gatsby.md Outdated
because this is going to be executed on every deploy it is suggested that you use an `package.json` script to simplify this process


## Providers
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps just link to a number of static hosts? There's no reason to prioritize Surge + it'll be perhaps hard for us to keep installation instructions up-to-date. Better I'd think to just send people off the hosting site?

@KyleAMathews
Copy link
Contributor

KyleAMathews commented Jul 12, 2017

deploy-gatsby.md Outdated
or alternatively
`Uncaught Error: Minified React error #32; visit http://facebook.github.io/react/docs/error-decoder.html?invariant=32&args[]=## for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`

This is a new problem when dealing with static sites built with react. React uses comments to help identify locations of components that render do not render anything. If you are using a CDN that minifies your HTML it will eliminate the comments used by react to take control of the page on the client.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • React should be capitalized
  • Say "HTML comments" not "comments"
  • Comma after "your HTML".

@KyleAMathews
Copy link
Contributor

Looking great! And one more thing I forgot. You need to add a link to the post in https://github.com/gatsbyjs/gatsby/blob/master/www/src/pages/docs/doc-links.yaml so it'll show up in the docs navigation.

@couturecraigj
Copy link
Contributor Author

Is there a particular location that you want it to be located... since it is still in its infancy it appears to fit in most of those locations.

@KyleAMathews
Copy link
Contributor

How about the quick start section. The general guidelines for this right now is general help that 80%+ would want to read goes in quick start and more specific stuff goes in guides.

@couturecraigj
Copy link
Contributor Author

And done.

remove additional render
@couturecraigj
Copy link
Contributor Author

Alright take a look now. I think that was everything.

@KyleAMathews KyleAMathews merged commit c7409fc into gatsbyjs:master Jul 12, 2017
@jlengstorf
Copy link
Contributor

Hiya @couturecraigj! 👋

This is definitely late, but on behalf of the entire Gatsby community, I wanted to say thank you for being here.

Gatsby is built by awesome people like you. Let us say “thanks” in two ways:

  1. We’d like to send you some Gatsby swag. As a token of our appreciation, you can go to the Gatsby Swag Store and log in with your GitHub account to get a coupon code good for one free piece of swag. (We’ve got t-shirts and hats, plus some socks that are really razzing our berries right now.)
  2. If you’re not already part of it, we just invited you to join the Gatsby organization on GitHub. This will add you to our team of maintainers. You’ll receive an email shortly asking you to confirm. By joining the team, you’ll be able to label issues, review pull requests, and merge approved pull requests.

If you have questions, please don’t hesitate to reach out to us: tweet at @gatsbyjs and we’ll come a-runnin’.

Thanks again! 💪💜

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants