Skip to content
This repository was archived by the owner on Jun 20, 2022. It is now read-only.

Commit 0696856

Browse files
committed
chore: use @bundle-analyzer/gatsby-plugin
1 parent 7da4d58 commit 0696856

File tree

4 files changed

+52
-13
lines changed

4 files changed

+52
-13
lines changed

website/gatsby-config.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,11 @@ module.exports = {
2323
component: require.resolve(`./src/components/layout`),
2424
},
2525
},
26+
{
27+
resolve: '@bundle-analyzer/gatsby-plugin',
28+
options: {
29+
token: '0f76d516797d28b3eac9999c701186d94360c766',
30+
},
31+
},
2632
],
2733
}

website/gatsby-node.js

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,7 @@
1-
const BundleAnalyzerPlugin = require('@bundle-analyzer/webpack-plugin')
2-
31
module.exports.createPages = ({ actions }) => {
42
actions.createRedirect({
53
fromPath: `/docs/`,
64
toPath: `/docs/getting-started/`,
75
redirectInBrowser: true,
86
})
97
}
10-
11-
exports.onCreateWebpackConfig = ({ actions }) => {
12-
actions.setWebpackConfig({
13-
plugins: [
14-
new BundleAnalyzerPlugin({
15-
token: '0f76d516797d28b3eac9999c701186d94360c766',
16-
}),
17-
],
18-
})
19-
}

website/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
"serve": "gatsby serve"
88
},
99
"dependencies": {
10+
"@bundle-analyzer/gatsby-plugin": "^0.4.0",
1011
"@bundle-analyzer/webpack-plugin": "^0.3.1",
1112
"@emotion/core": "^10.0.16",
1213
"@emotion/styled": "^10.0.15",

website/yarn.lock

Lines changed: 45 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -774,13 +774,38 @@
774774
gzip-size "^5.1.1"
775775
omit-deep "^0.3.0"
776776

777+
"@bundle-analyzer/core@^0.4.0":
778+
version "0.4.0"
779+
resolved "https://registry.yarnpkg.com/@bundle-analyzer/core/-/core-0.4.0.tgz#8cf972668d92dfd6a7cbfe8e159cb4a926d9d572"
780+
integrity sha512-dJT8BUTDbSFIX2ynKOLf7IYFRff5bIkB8GHAoF+thkhNLptl33+YZplOpQLAI++/ZNJlIJuPw//l/UpPEUERQw==
781+
dependencies:
782+
axios "^0.19.0"
783+
brotli-size "^1.0.0"
784+
cosmiconfig "^5.2.1"
785+
gzip-size "^5.1.1"
786+
omit-deep "^0.3.0"
787+
788+
"@bundle-analyzer/gatsby-plugin@^0.4.0":
789+
version "0.4.0"
790+
resolved "https://registry.yarnpkg.com/@bundle-analyzer/gatsby-plugin/-/gatsby-plugin-0.4.0.tgz#7d481ae7d0a2567c667f5be2e90baf893e29376e"
791+
integrity sha512-D/iGCfv/veLhwDdZyUqnLK0tCmH0YQF/2P3GL6ZbOeeIw8g6jKxDZdzBLXMiwweTIUZFCDoDjnEX1W4xYMI/Tg==
792+
dependencies:
793+
"@bundle-analyzer/webpack-plugin" "^0.4.0"
794+
777795
"@bundle-analyzer/webpack-plugin@^0.3.1":
778796
version "0.3.1"
779797
resolved "https://registry.yarnpkg.com/@bundle-analyzer/webpack-plugin/-/webpack-plugin-0.3.1.tgz#1877cf0a8494ca66619bd585ea5606fe3d5fce0a"
780798
integrity sha512-tL6q+YsO4tUWNdcaICQ/qteFRmxNVwIN22q0WyZLD29DEvchWlggixsA3cDi/9g8ThjQYusrmuYMmQO1rjVHNQ==
781799
dependencies:
782800
"@bundle-analyzer/core" "^0.3.1"
783801

802+
"@bundle-analyzer/webpack-plugin@^0.4.0":
803+
version "0.4.0"
804+
resolved "https://registry.yarnpkg.com/@bundle-analyzer/webpack-plugin/-/webpack-plugin-0.4.0.tgz#220a90a00277e170fc271a2f587f4e61db224d05"
805+
integrity sha512-Ak88ObUJVTRTO3u0WDfg38YwEfOpmT9YMjnpX8SAuWW6KuQmBVN/frtt4RkzBc+UfgxVIJ0mPjUV967WRLOsnQ==
806+
dependencies:
807+
"@bundle-analyzer/core" "^0.4.0"
808+
784809
"@emotion/cache@^10.0.15":
785810
version "10.0.15"
786811
resolved "https://registry.yarnpkg.com/@emotion/cache/-/cache-10.0.15.tgz#b81767b48015aae2689c60373992145c67b8de02"
@@ -2557,6 +2582,14 @@ brorand@^1.0.1:
25572582
resolved "https://registry.yarnpkg.com/brorand/-/brorand-1.1.0.tgz#12c25efe40a45e3c323eb8675a0a0ce57b22371f"
25582583
integrity sha1-EsJe/kCkXjwyPrhnWgoM5XsiNx8=
25592584

2585+
brotli-size@^1.0.0:
2586+
version "1.0.0"
2587+
resolved "https://registry.yarnpkg.com/brotli-size/-/brotli-size-1.0.0.tgz#9dde191db7c5519cf21eb872c58794ec12811a5a"
2588+
integrity sha512-vLc7vUKuDh1GsxeWW+X0epesdhxVRG5h2uuF6YlV67xlI/r5tRWSXeiZRNX7GpuYr8p1LLKGsxt/MyQ+o0zG6Q==
2589+
dependencies:
2590+
duplexer "^0.1.1"
2591+
iltorb "^2.4.3"
2592+
25602593
brotli-size@^4.0.0:
25612594
version "4.0.0"
25622595
resolved "https://registry.yarnpkg.com/brotli-size/-/brotli-size-4.0.0.tgz#a05ee3faad3c0e700a2f2da826ba6b4d76e69e5e"
@@ -6790,6 +6823,17 @@ ignore@^5.1.1:
67906823
resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.1.4.tgz#84b7b3dbe64552b6ef0eca99f6743dbec6d97adf"
67916824
integrity sha512-MzbUSahkTW1u7JpKKjY7LCARd1fU5W2rLdxlM4kdkayuCwZImjkpluF9CM1aLewYJguPDqewLam18Y6AU69A8A==
67926825

6826+
iltorb@^2.4.3:
6827+
version "2.4.3"
6828+
resolved "https://registry.yarnpkg.com/iltorb/-/iltorb-2.4.3.tgz#b489689d24c8a25a2cf170c515f97954edd45577"
6829+
integrity sha512-cr/kC07Cf9sW3TWH7yUxV2QkNjby4LMCsXGmxPCQs5x//QzTpF3GLPNY7L66G+DkNGaTRCgY+vYZ+dyAcuDOnQ==
6830+
dependencies:
6831+
detect-libc "^1.0.3"
6832+
nan "^2.13.2"
6833+
npmlog "^4.1.2"
6834+
prebuild-install "^5.3.0"
6835+
which-pm-runs "^1.0.0"
6836+
67936837
imagemin-mozjpeg@^8.0.0:
67946838
version "8.0.0"
67956839
resolved "https://registry.yarnpkg.com/imagemin-mozjpeg/-/imagemin-mozjpeg-8.0.0.tgz#d2ca4e8c982c7c6eda55069af89dee4c1cebcdfd"
@@ -8695,7 +8739,7 @@ name-all-modules-plugin@^1.0.1:
86958739
resolved "https://registry.yarnpkg.com/name-all-modules-plugin/-/name-all-modules-plugin-1.0.1.tgz#0abfb6ad835718b9fb4def0674e06657a954375c"
86968740
integrity sha1-Cr+2rYNXGLn7Te8GdOBmV6lUN1w=
86978741

8698-
nan@^2.12.1, nan@^2.14.0:
8742+
nan@^2.12.1, nan@^2.13.2, nan@^2.14.0:
86998743
version "2.14.0"
87008744
resolved "https://registry.yarnpkg.com/nan/-/nan-2.14.0.tgz#7818f722027b2459a86f0295d434d1fc2336c52c"
87018745
integrity sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg==

0 commit comments

Comments
 (0)