Skip to content

Commit

Permalink
Merge branch 'master' into renovate/major-gatsby-plugin-gatsby-cloud-…
Browse files Browse the repository at this point in the history
…dev-major
  • Loading branch information
LekoArts committed Jan 3, 2022
2 parents e8339ec + fc3e7b7 commit d12bf3f
Show file tree
Hide file tree
Showing 27 changed files with 300 additions and 340 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ Gatsby is a modern web framework for blazing fast websites.
limitations. Gatsby sites are fully functional React apps, so you can create high-quality,
dynamic web apps, from blogs to e-commerce sites to user dashboards.

- **Choose your Rendering Option.** You can choose alternative [rendering options](https://gatsbyjs.com/docs/conceptual/rendering-options/), namely Deferred Static Generation (DSG) and Server-Side Rendering (SSR), in addition to Static Site Generation (SSG) — on a per-page basis. This type of granular control allows you to optimize for performance and productivity without sacrificing one for the other.
- **Choose your Rendering Options.** You can choose alternative [rendering options](https://gatsbyjs.com/docs/conceptual/rendering-options/), namely Deferred Static Generation (DSG) and Server-Side Rendering (SSR), in addition to Static Site Generation (SSG) — on a per-page basis. This type of granular control allows you to optimize for performance and productivity without sacrificing one for the other.

- **Use a Modern Stack for Every Site.** No matter where the data comes from, Gatsby sites are
built using React and GraphQL. Build a uniform workflow for you and your team, regardless of
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,6 @@ This framework also has experimental support for the React suspense API and it s

- [Gatsby i18n packages](https://www.gatsbyjs.com/plugins/gatsby-plugin-i18n/?=i18)

- [Gatsby i18n articles](https://www.gatsbyjs.com/blog/tags/i18n/)
- [Gatsby i18n articles](https://www.gatsbyjs.com/blog/tags/localization/)

- [W3C's i18n resources](https://w3c.github.io/i18n-drafts/getting-started/contentdev.en#reference)
2 changes: 1 addition & 1 deletion docs/docs/how-to/styling/global-css.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Globally-scoped CSS rules are declared in external `.css` stylesheets, and [CSS

## Adding global styles with a layout component

The best way to add global styles is with a [shared layout component](/docs/tutorial/part-3/#your-first-layout-component). This layout component is used for things that are shared throughout the site, including styles, header components, and other common items.
The best way to add global styles is with a [shared layout component](/docs/tutorial/part-2/#create-a-reusable-layout-component). This layout component is used for things that are shared throughout the site, including styles, header components, and other common items.

> **NOTE:** This pattern is implemented by default in [the default starter](https://github.com/gatsbyjs/gatsby-starter-default/blob/063978d59f74103da45d5880a61ebd2e77798e3c/src/components/layout.js#L13).
Expand Down
2 changes: 1 addition & 1 deletion docs/docs/recipes/pages-layouts.md
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ export default function Home() {

### Additional resources

- Create a layout component in [tutorial part three](/docs/tutorial/part-3/#your-first-layout-component)
- Create a layout component in [tutorial part three](/docs/tutorial/part-2/#create-a-reusable-layout-component)
- Styling with [Layout Components](/docs/how-to/routing/layout-components/)

## Creating pages programmatically with createPage
Expand Down
2 changes: 1 addition & 1 deletion docs/docs/recipes/styling-css.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ import "./src/styles/global.css"

### Directions

You can add global styles to a [shared layout component](/docs/tutorial/part-3/#your-first-layout-component). This component is used for things that are common throughout the site, like a header or footer.
You can add global styles to a [shared layout component](/docs/tutorial/part-2/#create-a-reusable-layout-component). This component is used for things that are common throughout the site, like a header or footer.

1. If you don't already have one, create a new directory in your site at `/src/components`.

Expand Down
21 changes: 6 additions & 15 deletions examples/using-mobx/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@
"scripts": {
"build": "gatsby build",
"develop": "gatsby develop",
"format": "prettier --write \"src/**/*.js\"",
"lint": "eslint **/*.{js,jsx} --quiet -o linterrors.txt --ignore-path .gitignore"
"format": "prettier --write \"src/**/*.js\""
},
"keywords": [
"gatsby",
Expand All @@ -17,21 +16,13 @@
"license": "MIT",
"dependencies": {
"gatsby": "next",
"mobx": "^5.15.7",
"mobx-react": "^6.3.0",
"prop-types": "^15.7.2",
"react": "^16.9.0",
"react-dom": "^16.9.0"
"mobx": "^6.3.10",
"mobx-react": "^7.2.1",
"prop-types": "^15.8.0",
"react": "^17.0.1",
"react-dom": "^17.0.1"
},
"devDependencies": {
"babel-eslint": "^10.1.0",
"eslint": "^6.8.0",
"eslint-config-airbnb": "^18.2.0",
"eslint-config-prettier": "^6.11.0",
"eslint-plugin-import": "^2.22.0",
"eslint-plugin-jsx-a11y": "^6.3.1",
"eslint-plugin-prettier": "^3.1.4",
"eslint-plugin-react": "^7.20.6",
"prettier": "2.1.1"
}
}
17 changes: 9 additions & 8 deletions examples/using-mobx/src/components/Counter.js
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
import React, { Fragment } from "react"
import { observer, inject } from "mobx-react"
import React, { useContext } from "react"
import { MobXProviderContext, observer } from "mobx-react"

const Counter = inject(`store`)(
observer(({ store }) => (
<Fragment>
const Counter = observer(() => {
const store = useContext(MobXProviderContext)
return (
<>
<div>Counted to: {store.Count}</div>
<div>
<button onClick={() => store.Increment()}>Add</button>
<button onClick={() => store.Decrement()}>Subtract</button>
</div>
</Fragment>
))
)
</>
)
})

export default Counter
16 changes: 10 additions & 6 deletions examples/using-mobx/src/models/CounterModel.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,16 @@
import { observable, action, decorate } from "mobx"
import { observable, action, makeObservable } from "mobx"

class CounterModel {
Count = 0

constructor() {
makeObservable(this, {
Count: observable,
Increment: action.bound,
Decrement: action.bound,
})
}

Increment() {
this.Count += 1
}
Expand All @@ -11,10 +19,6 @@ class CounterModel {
this.Count -= 1
}
}
decorate(CounterModel, {
Count: observable,
Increment: action,
Decrement: action,
})

const CounterStore = new CounterModel()
export default CounterStore
12 changes: 8 additions & 4 deletions examples/using-mobx/wrap-with-provider.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
import React from "react"
import { Provider } from "mobx-react"
import { enableStaticRendering, MobXProviderContext } from "mobx-react"
import CounterStore from "./src/models/CounterModel"

// eslint-disable-next-line react/display-name,react/prop-types
export default ({ element }) => (
<Provider store={CounterStore}>{element}</Provider>
// https://mobx.js.org/react-integration.html#static-rendering
enableStaticRendering(true)

const App =({ element }) => (
<MobXProviderContext.Provider value={CounterStore}>{element}</MobXProviderContext.Provider>
)

export default App;
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-filenames": "^1.3.2",
"eslint-plugin-flowtype": "^6.1.1",
"eslint-plugin-import": "^2.25.3",
"eslint-plugin-import": "^2.25.4",
"eslint-plugin-jsx-a11y": "^6.5.1",
"eslint-plugin-prettier": "^4.0.0",
"eslint-plugin-react": "^7.27.1",
"eslint-plugin-react": "^7.28.0",
"fs-extra": "^10.0.0",
"glob": "^7.1.7",
"husky": "3.1.0",
Expand All @@ -62,7 +62,7 @@
"npm-packlist": "^2.1.5",
"npm-run-all": "4.1.5",
"plop": "^1.9.1",
"prettier": "2.5.0",
"prettier": "2.5.1",
"remark": "^13.0.0",
"remark-cli": "^9.0.0",
"remark-frontmatter": "^3.0.0",
Expand All @@ -85,7 +85,7 @@
"retext-syntax-urls": "^2.0.0",
"rimraf": "^3.0.2",
"svgo": "1.3.2",
"typescript": "^4.5.2",
"typescript": "^4.5.4",
"unified": "^9.2.0",
"yargs": "^15.4.1"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/gatsby-cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,10 @@
"npm-run-all": "4.1.5",
"react": "^16.9.0",
"rimraf": "^3.0.2",
"rollup": "^2.60.2",
"rollup": "^2.62.0",
"rollup-plugin-auto-external": "^2.0.0",
"rollup-plugin-internal": "^1.0.4",
"typescript": "^4.5.2"
"typescript": "^4.5.4"
},
"files": [
"lib/",
Expand Down
2 changes: 1 addition & 1 deletion packages/gatsby-codemods/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
"@babel/plugin-syntax-typescript": "^7.14.0",
"@babel/runtime": "^7.15.4",
"execa": "^5.1.1",
"graphql": "^15.7.2",
"graphql": "^15.8.0",
"jscodeshift": "^0.12.0",
"recast": "^0.20.5"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/gatsby-core-utils/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@
"babel-preset-gatsby-package": "^2.5.0-next.0",
"cross-env": "^7.0.3",
"is-uuid": "^1.0.2",
"msw": "^0.35.0",
"typescript": "^4.5.2"
"msw": "^0.36.3",
"typescript": "^4.5.4"
},
"engines": {
"node": ">=14.15.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/gatsby-page-utils/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
"babel-preset-gatsby-package": "^2.5.0-next.0",
"cross-env": "^7.0.3",
"rimraf": "^3.0.2",
"typescript": "^4.5.2"
"typescript": "^4.5.4"
},
"files": [
"dist/"
Expand Down
6 changes: 3 additions & 3 deletions packages/gatsby-plugin-gatsby-cloud/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
},
"dependencies": {
"@babel/runtime": "^7.15.4",
"date-fns": "^2.27.0",
"date-fns": "^2.28.0",
"fs-extra": "^10.0.0",
"gatsby-core-utils": "^3.5.0-next.2",
"gatsby-telemetry": "^3.5.0-next.2",
Expand All @@ -20,14 +20,14 @@
"@babel/cli": "^7.15.4",
"@babel/core": "^7.15.5",
"@testing-library/dom": "^8.11.1",
"@testing-library/jest-dom": "^5.15.1",
"@testing-library/jest-dom": "^5.16.1",
"@testing-library/react": "^11.2.7",
"@testing-library/user-event": "^13.5.0",
"babel-preset-gatsby-package": "^2.5.0-next.0",
"cpy-cli": "^3.1.1",
"cross-env": "^7.0.3",
"del-cli": "^4.0.1",
"msw": "^0.35.0",
"msw": "^0.36.3",
"node-fetch": "^3.1.0"
},
"homepage": "https://github.com/gatsbyjs/gatsby/tree/master/packages/gatsby-plugin-gatsby-cloud#readme",
Expand Down
2 changes: 1 addition & 1 deletion packages/gatsby-plugin-image/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
"npm-run-all": "^4.1.5",
"postcss": "^8.2.9",
"terser": "^5.3.8",
"typescript": "^4.5.2"
"typescript": "^4.5.4"
},
"peerDependencies": {
"@babel/core": "^7.12.3",
Expand Down
2 changes: 1 addition & 1 deletion packages/gatsby-plugin-offline/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
"cpy-cli": "^3.1.1",
"cross-env": "^7.0.3",
"gatsby-plugin-utils": "^2.5.0-next.0",
"rewire": "^5.0.0"
"rewire": "^6.0.0"
},
"homepage": "https://github.com/gatsbyjs/gatsby/tree/master/packages/gatsby-plugin-offline#readme",
"keywords": [
Expand Down
4 changes: 2 additions & 2 deletions packages/gatsby-plugin-sass/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@
},
"dependencies": {
"@babel/runtime": "^7.15.4",
"resolve-url-loader": "^3.1.2",
"resolve-url-loader": "^3.1.4",
"sass-loader": "^10.1.1"
},
"devDependencies": {
"@babel/cli": "^7.15.4",
"@babel/core": "^7.15.5",
"autoprefixer": "^10.4.0",
"autoprefixer": "^10.4.1",
"babel-preset-gatsby-package": "^2.5.0-next.0",
"cross-env": "^7.0.3",
"gatsby-plugin-utils": "^2.5.0-next.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/gatsby-plugin-sharp/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"devDependencies": {
"@babel/cli": "^7.15.4",
"@babel/core": "^7.15.5",
"@types/sharp": "^0.29.4",
"@types/sharp": "^0.29.5",
"babel-preset-gatsby-package": "^2.5.0-next.0",
"cross-env": "^7.0.3",
"gatsby-plugin-image": "^2.5.0-next.2"
Expand Down
2 changes: 1 addition & 1 deletion packages/gatsby-plugin-utils/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
"babel-preset-gatsby-package": "^2.5.0-next.0",
"cross-env": "^7.0.3",
"rimraf": "^3.0.2",
"typescript": "^4.5.2"
"typescript": "^4.5.4"
},
"peerDependencies": {
"gatsby": "^4.0.0-next"
Expand Down
6 changes: 3 additions & 3 deletions packages/gatsby-source-drupal/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@
"dependencies": {
"@babel/runtime": "^7.15.4",
"@opentelemetry/semantic-conventions": "0.26.0",
"agentkeepalive": "^4.1.4",
"agentkeepalive": "^4.2.0",
"bluebird": "^3.7.2",
"body-parser": "^1.19.0",
"body-parser": "^1.19.1",
"fastq": "^1.13.0",
"gatsby-source-filesystem": "^4.5.0-next.2",
"got": "^11.8.3",
"http2-wrapper": "^2.1.9",
"http2-wrapper": "^2.1.10",
"lodash": "^4.17.21",
"opentracing": "^0.14.5",
"tiny-async-pool": "^1.2.0",
Expand Down
4 changes: 2 additions & 2 deletions packages/gatsby-source-shopify/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,14 @@
"devDependencies": {
"@types/node": "^14.17.34",
"@types/node-fetch": "^2.5.12",
"@types/sharp": "^0.29.4",
"@types/sharp": "^0.29.5",
"cross-env": "^7.0.3",
"gatsby-plugin-image": "^2.5.0-next.2",
"msw": "^0.35.0",
"prettier": "^2.5.1",
"prettier-check": "^2.0.0",
"tsc-watch": "^4.5.0",
"typescript": "^4.5.2"
"typescript": "^4.5.4"
},
"peerDependencies": {
"gatsby-plugin-image": "^1.1.0 || ^2.0.0-next"
Expand Down
2 changes: 1 addition & 1 deletion packages/gatsby-telemetry/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"babel-preset-gatsby-package": "^2.5.0-next.0",
"cross-env": "^7.0.3",
"rimraf": "^3.0.2",
"typescript": "^4.5.2"
"typescript": "^4.5.4"
},
"files": [
"lib/",
Expand Down
2 changes: 1 addition & 1 deletion packages/gatsby-transformer-sharp/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"devDependencies": {
"@babel/cli": "^7.15.4",
"@babel/core": "^7.15.5",
"@types/sharp": "^0.29.4",
"@types/sharp": "^0.29.5",
"babel-preset-gatsby-package": "^2.5.0-next.0",
"cross-env": "^7.0.3"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/gatsby-worker/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"babel-preset-gatsby-package": "^2.5.0-next.0",
"cross-env": "^7.0.3",
"rimraf": "^3.0.2",
"typescript": "^4.5.2"
"typescript": "^4.5.4"
},
"homepage": "https://github.com/gatsbyjs/gatsby/tree/master/packages/gatsby-worker#readme",
"keywords": [
Expand Down
6 changes: 3 additions & 3 deletions packages/gatsby/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
"eslint-plugin-graphql": "^4.0.0",
"eslint-plugin-import": "^2.25.3",
"eslint-plugin-jsx-a11y": "^6.5.1",
"eslint-plugin-react": "^7.27.1",
"eslint-plugin-react": "^7.28.0",
"eslint-plugin-react-hooks": "^4.3.0",
"eslint-webpack-plugin": "^2.6.0",
"event-source-polyfill": "^1.0.25",
Expand Down Expand Up @@ -182,7 +182,7 @@
"react": "^16.12.0",
"react-dom": "^16.12.0",
"rimraf": "^3.0.2",
"typescript": "^4.5.2",
"typescript": "^4.5.4",
"xhr-mock": "^2.5.1",
"zipkin": "^0.22.0",
"zipkin-javascript-opentracing": "^3.0.0",
Expand Down Expand Up @@ -232,7 +232,7 @@
"url": "git+https://github.com/gatsbyjs/gatsby.git"
},
"resolutions": {
"graphql": "^15.7.2",
"graphql": "^15.8.0",
"@mdx-js/mdx": "^2.0.0-next.3",
"@mdx-js/react": "^2.0.0-next.3",
"@mdx-js/runtime": "^2.0.0-next.3",
Expand Down

0 comments on commit d12bf3f

Please sign in to comment.