Skip to content

Commit d44b07f

Browse files
authored
Merge pull request newrelic#5360 from newrelic/ru/gatsby-400
feat: upgrade to Gatsby 4.3.0
2 parents 85cc74c + b6e4e27 commit d44b07f

File tree

3 files changed

+1071
-651
lines changed

3 files changed

+1071
-651
lines changed

gatsby-node.js

+12-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ const fs = require('fs');
22
const path = require('path');
33
const { prop } = require('./scripts/utils/functional.js');
44
const externalRedirects = require('./src/data/external-redirects.json');
5-
65
const { createFilePath } = require('gatsby-source-filesystem');
76

87
const SWIFTYPE_RESOURCES_DIR = 'src/data/swiftype-resources';
@@ -18,6 +17,18 @@ const hasTrailingSlash = (pathname) =>
1817
const appendTrailingSlash = (pathname) =>
1918
pathname.endsWith('/') ? pathname : `${pathname}/`;
2019

20+
exports.onCreateWebpackConfig = ({ actions }) => {
21+
actions.setWebpackConfig({
22+
resolve: {
23+
fallback: {
24+
http: false,
25+
https: false,
26+
zlib: false,
27+
},
28+
},
29+
});
30+
};
31+
2132
// before we build, combine related resource files into one
2233
exports.onPreBootstrap = () => {
2334
const files = fs.readdirSync(SWIFTYPE_RESOURCES_DIR);

package.json

+16-16
Original file line numberDiff line numberDiff line change
@@ -15,24 +15,24 @@
1515
"common-tags": "^1.8.0",
1616
"date-fns": "^2.17.0",
1717
"front-matter": "^4.0.2",
18-
"gatsby": "^3.14.0",
19-
"gatsby-image": "^3.8.0",
20-
"gatsby-plugin-gatsby-cloud": "^2.8.1",
18+
"gatsby": "^4.0.0",
19+
"gatsby-image": "^3.11.0",
20+
"gatsby-plugin-gatsby-cloud": "^4.4.0",
2121
"gatsby-plugin-json-output": "^1.2.0",
22-
"gatsby-plugin-manifest": "^3.8.0",
23-
"gatsby-plugin-mdx": "^2.13.0",
22+
"gatsby-plugin-manifest": "^4.4.0",
23+
"gatsby-plugin-mdx": "^3.4.0",
2424
"gatsby-plugin-meta-redirect": "^1.1.1",
25-
"gatsby-plugin-offline": "^4.8.0",
26-
"gatsby-plugin-react-helmet": "^4.8.0",
27-
"gatsby-plugin-sharp": "^3.14.3",
28-
"gatsby-remark-autolink-headers": "^4.5.0",
29-
"gatsby-remark-copy-linked-files": "^4.5.0",
30-
"gatsby-remark-images": "^5.5.0",
31-
"gatsby-source-filesystem": "^3.8.0",
32-
"gatsby-transformer-json": "^3.8.0",
33-
"gatsby-transformer-remark": "^4.5.0",
34-
"gatsby-transformer-sharp": "^3.8.0",
35-
"gatsby-transformer-yaml": "^3.8.0",
25+
"gatsby-plugin-offline": "^5.4.0",
26+
"gatsby-plugin-react-helmet": "^5.4.0",
27+
"gatsby-plugin-sharp": "^4.4.0",
28+
"gatsby-remark-autolink-headers": "^5.4.0",
29+
"gatsby-remark-copy-linked-files": "^5.4.0",
30+
"gatsby-remark-images": "^6.4.0",
31+
"gatsby-source-filesystem": "^4.4.0",
32+
"gatsby-transformer-json": "^4.4.0",
33+
"gatsby-transformer-remark": "^5.4.0",
34+
"gatsby-transformer-sharp": "^4.4.0",
35+
"gatsby-transformer-yaml": "^4.4.0",
3636
"github-slugger": "^1.3.0",
3737
"hast-util-from-dom": "^3.0.0",
3838
"hast-util-has-property": "^1.0.4",

0 commit comments

Comments
 (0)