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

Add babelrc to gatsby-plugin-netlify-cms to stop Uglify failure #4233

Merged
merged 1 commit into from
Feb 26, 2018

Conversation

martynhoyer
Copy link
Contributor

Stops UglifyJS failing at build

As per #4227

@gatsbybot
Copy link
Collaborator

gatsbybot commented Feb 25, 2018

Deploy preview for gatsbygram ready!

Built with commit b2e3239

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

@martynhoyer
Copy link
Contributor Author

Hah, ok... Travis fails because it wants backticks...

@pieh
Copy link
Contributor

pieh commented Feb 25, 2018

@martynhoyer you can move gatsby-browser out of src dir to root directory - gatsby-browser.js is handled by webpack during build so this should work ok.

@erquhart
Copy link
Contributor

erquhart commented Feb 25, 2018

The plugin source files should remain in the src directory.

@KyleAMathews I see other plugins, like jss,
having similar code, and presumably not having issues with Uglify. Any thoughts on why?

@pieh
Copy link
Contributor

pieh commented Feb 25, 2018

@erquhart propably because they have this .babelrc - https://github.com/gatsbyjs/gatsby/blob/master/packages/gatsby-plugin-jss/.babelrc and generated output is fit for browsers

@erquhart
Copy link
Contributor

Ah! Good catch, thank you.

@martynhoyer would you mind updating your PR to just add that babelrc?

@martynhoyer martynhoyer changed the title Remove backticks from gatsby-browser.js Add babelrc to gatsby-plugin-netlify-cms to stop Uglify failure Feb 25, 2018
@martynhoyer
Copy link
Contributor Author

@erquhart sure, that's done now.

@martynhoyer
Copy link
Contributor Author

Not sure why the netlify check is failing, it says gatsby not found, but looking at the history of that Netlify deployment, it doesn't look like it's ever published successfully.

@pieh
Copy link
Contributor

pieh commented Feb 25, 2018

Don't worry about netlify "test" too much - it just fails for some examples

@erquhart erquhart merged commit 6698317 into gatsbyjs:master Feb 26, 2018
@TheTFo
Copy link

TheTFo commented Mar 26, 2018

Is this scheduled for release?

@KyleAMathews
Copy link
Contributor

Merged code is generally released immediately. Upgrade to the latest version of this package to get it.

@TheTFo
Copy link

TheTFo commented Mar 26, 2018

Ugh, I apologize. I set this up last night thinking I had the latest, but I forgot that I used netlify to deploy my site, and their seed is using 1.0.9.

Updated to 1.0.12 worked like a charm.

@jlengstorf
Copy link
Contributor

Hiya @martynhoyer! 👋

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.

7 participants