Skip to content

Commit b833f26

Browse files
authored
chore: Misc initial setup fixes (#233)
* define yarn version * run format script * random ts update
1 parent 2a77d82 commit b833f26

File tree

8 files changed

+618
-689
lines changed

8 files changed

+618
-689
lines changed

.github/workflows/fossa.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,3 @@ jobs:
3535
run: fossa analyze --debug
3636
env:
3737
FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY }}
38-

.github/workflows/labeler.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,7 @@ on:
55

66
jobs:
77
label-pr:
8-
if:
9-
github.event_name == 'pull_request' &&
10-
github.event.pull_request.head.repo.fork == false
8+
if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.fork == false
119
runs-on: ubuntu-latest
1210
strategy:
1311
matrix:

.github/workflows/pre-release.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ jobs:
1111
- uses: actions/checkout@v2
1212
- uses: actions/setup-node@v3
1313
with:
14-
node-version: "*"
15-
cache: "npm"
14+
node-version: '*'
15+
cache: 'npm'
1616
check-latest: true
17-
registry-url: "https://registry.npmjs.org"
17+
registry-url: 'https://registry.npmjs.org'
1818
- name: Install core dependencies
1919
run: npm ci --no-audit
2020
- name: Extract tag and version

.github/workflows/stalebot.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,9 @@ jobs:
1212
exempt-issue-labels: 'WIP,security,action_item,never_stale'
1313
days-before-issue-stale: 365
1414
stale-issue-label: 'stale'
15-
stale-issue-message: 'This issue has been automatically marked as stale because it has not had activity in 1 year. It will be closed in 7 days if no further activity occurs. Thanks!'
15+
stale-issue-message:
16+
'This issue has been automatically marked as stale because it has not had activity in 1 year. It will be
17+
closed in 7 days if no further activity occurs. Thanks!'
1618
days-before-issue-close: 7
1719
close-issue-message: 'This issue was closed because it had no activity for over 1 year.'
1820
days-before-pr-close: -1

CHANGELOG.md

Lines changed: 28 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -5,74 +5,80 @@ All notable changes to this project will be documented in this file. See
55

66
## [5.1.0](https://www.github.com/netlify/gatsby-plugin-netlify/compare/v5.0.1...v5.1.0) (2022-11-30)
77

8-
98
### Features
109

11-
* support Gatsby v5 ([#203](https://www.github.com/netlify/gatsby-plugin-netlify/issues/203)) ([5bda14f](https://www.github.com/netlify/gatsby-plugin-netlify/commit/5bda14f3da4a1e0d8faefab3eca8536095796318))
12-
10+
- support Gatsby v5 ([#203](https://www.github.com/netlify/gatsby-plugin-netlify/issues/203))
11+
([5bda14f](https://www.github.com/netlify/gatsby-plugin-netlify/commit/5bda14f3da4a1e0d8faefab3eca8536095796318))
1312

1413
### Bug Fixes
1514

16-
* **deps:** update dependency @babel/runtime to v7.19.4 ([#186](https://www.github.com/netlify/gatsby-plugin-netlify/issues/186)) ([0f51e02](https://www.github.com/netlify/gatsby-plugin-netlify/commit/0f51e020da5e55830754b39d78252eb3339f67cd))
17-
* **deps:** update dependency @babel/runtime to v7.20.0 ([#192](https://www.github.com/netlify/gatsby-plugin-netlify/issues/192)) ([214e991](https://www.github.com/netlify/gatsby-plugin-netlify/commit/214e991d48c98dc37575284788d468a5a4ed5f5e))
15+
- **deps:** update dependency @babel/runtime to v7.19.4
16+
([#186](https://www.github.com/netlify/gatsby-plugin-netlify/issues/186))
17+
([0f51e02](https://www.github.com/netlify/gatsby-plugin-netlify/commit/0f51e020da5e55830754b39d78252eb3339f67cd))
18+
- **deps:** update dependency @babel/runtime to v7.20.0
19+
([#192](https://www.github.com/netlify/gatsby-plugin-netlify/issues/192))
20+
([214e991](https://www.github.com/netlify/gatsby-plugin-netlify/commit/214e991d48c98dc37575284788d468a5a4ed5f5e))
1821

1922
### [5.0.1](https://www.github.com/netlify/gatsby-plugin-netlify/compare/v5.0.0...v5.0.1) (2022-07-25)
2023

21-
2224
### Bug Fixes
2325

24-
* **deps:** update dependency fs-extra to v10.1.0 ([#145](https://www.github.com/netlify/gatsby-plugin-netlify/issues/145)) ([1e4cdf5](https://www.github.com/netlify/gatsby-plugin-netlify/commit/1e4cdf503efe10d2649cbc063e422c4f8e5f2557))
26+
- **deps:** update dependency fs-extra to v10.1.0
27+
([#145](https://www.github.com/netlify/gatsby-plugin-netlify/issues/145))
28+
([1e4cdf5](https://www.github.com/netlify/gatsby-plugin-netlify/commit/1e4cdf503efe10d2649cbc063e422c4f8e5f2557))
2529

2630
## [5.0.0](https://www.github.com/netlify/gatsby-plugin-netlify/compare/v4.4.0...v5.0.0) (2022-05-24)
2731

28-
2932
### ⚠ BREAKING CHANGES
3033

31-
* Remove script preloading (#134)
34+
- Remove script preloading (#134)
3235

3336
### Features
3437

35-
* Remove script preloading ([#134](https://www.github.com/netlify/gatsby-plugin-netlify/issues/134)) ([5a0397a](https://www.github.com/netlify/gatsby-plugin-netlify/commit/5a0397a8c80914070de03445538d7449ca085cad))
38+
- Remove script preloading ([#134](https://www.github.com/netlify/gatsby-plugin-netlify/issues/134))
39+
([5a0397a](https://www.github.com/netlify/gatsby-plugin-netlify/commit/5a0397a8c80914070de03445538d7449ca085cad))
3640

3741
## [4.4.0](https://www.github.com/netlify/gatsby-plugin-netlify/compare/v4.3.1...v4.4.0) (2022-05-18)
3842

39-
4043
### Features
4144

42-
* write granular info into skip file ([#128](https://www.github.com/netlify/gatsby-plugin-netlify/issues/128)) ([abefe10](https://www.github.com/netlify/gatsby-plugin-netlify/commit/abefe10bcf5cf28ba1eaf1372ac513315797725e))
45+
- write granular info into skip file ([#128](https://www.github.com/netlify/gatsby-plugin-netlify/issues/128))
46+
([abefe10](https://www.github.com/netlify/gatsby-plugin-netlify/commit/abefe10bcf5cf28ba1eaf1372ac513315797725e))
4347

4448
### [4.3.1](https://www.github.com/netlify/gatsby-plugin-netlify/compare/v4.3.0...v4.3.1) (2022-04-27)
4549

46-
4750
### Bug Fixes
4851

49-
* redirect named splat filesystem routes correctly for SSR/DSG pages ([#120](https://www.github.com/netlify/gatsby-plugin-netlify/issues/120)) ([cebe8d8](https://www.github.com/netlify/gatsby-plugin-netlify/commit/cebe8d85740c1148702994faf2fa2477e9c1e197))
52+
- redirect named splat filesystem routes correctly for SSR/DSG pages
53+
([#120](https://www.github.com/netlify/gatsby-plugin-netlify/issues/120))
54+
([cebe8d8](https://www.github.com/netlify/gatsby-plugin-netlify/commit/cebe8d85740c1148702994faf2fa2477e9c1e197))
5055

5156
## [4.3.0](https://www.github.com/netlify/gatsby-plugin-netlify/compare/v4.2.0...v4.3.0) (2022-04-20)
5257

53-
5458
### Features
5559

56-
* Add support for advanced redirect types ([#117](https://www.github.com/netlify/gatsby-plugin-netlify/issues/117)) ([d547a28](https://www.github.com/netlify/gatsby-plugin-netlify/commit/d547a28dfdd193c0cf38b26b9c24e4fb2c5c3fee))
60+
- Add support for advanced redirect types ([#117](https://www.github.com/netlify/gatsby-plugin-netlify/issues/117))
61+
([d547a28](https://www.github.com/netlify/gatsby-plugin-netlify/commit/d547a28dfdd193c0cf38b26b9c24e4fb2c5c3fee))
5762

5863
## [4.2.0](https://www.github.com/netlify/gatsby-plugin-netlify/compare/v4.1.0...v4.2.0) (2022-04-04)
5964

60-
6165
### Features
6266

63-
* add redirects for DSG pages ([#102](https://www.github.com/netlify/gatsby-plugin-netlify/issues/102)) ([3efa580](https://www.github.com/netlify/gatsby-plugin-netlify/commit/3efa580f3c469c2e394e5e55ce4ff7aa0d0425d7))
64-
67+
- add redirects for DSG pages ([#102](https://www.github.com/netlify/gatsby-plugin-netlify/issues/102))
68+
([3efa580](https://www.github.com/netlify/gatsby-plugin-netlify/commit/3efa580f3c469c2e394e5e55ce4ff7aa0d0425d7))
6569

6670
### Bug Fixes
6771

68-
* **deps:** update dependency fs-extra to v10.0.1 ([#86](https://www.github.com/netlify/gatsby-plugin-netlify/issues/86)) ([ea7e98e](https://www.github.com/netlify/gatsby-plugin-netlify/commit/ea7e98e7a916e6984b0a61b11b2222b7884ef832))
72+
- **deps:** update dependency fs-extra to v10.0.1
73+
([#86](https://www.github.com/netlify/gatsby-plugin-netlify/issues/86))
74+
([ea7e98e](https://www.github.com/netlify/gatsby-plugin-netlify/commit/ea7e98e7a916e6984b0a61b11b2222b7884ef832))
6975

7076
## [4.1.0](https://www.github.com/netlify/gatsby-plugin-netlify/compare/v4.0.0...v4.1.0) (2022-01-26)
7177

72-
7378
### Features
7479

75-
* disable Netlify functions if not needed ([#65](https://www.github.com/netlify/gatsby-plugin-netlify/issues/65)) ([d4ed977](https://www.github.com/netlify/gatsby-plugin-netlify/commit/d4ed97755a57cb3b9185d00b087186197967a692))
80+
- disable Netlify functions if not needed ([#65](https://www.github.com/netlify/gatsby-plugin-netlify/issues/65))
81+
([d4ed977](https://www.github.com/netlify/gatsby-plugin-netlify/commit/d4ed97755a57cb3b9185d00b087186197967a692))
7682

7783
## 4.0.0 (2022-01-19)
7884

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,5 +67,6 @@
6767
},
6868
"engines": {
6969
"node": ">=14.0.0"
70-
}
70+
},
71+
"packageManager": "[email protected]"
7172
}

src/gatsby-node.ts

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
import { join } from 'path'
33

44
import { writeJson, remove } from 'fs-extra'
5+
import type { GatsbyNode } from 'gatsby'
56
import { generatePageDataPath } from 'gatsby-core-utils'
67
import WebpackAssetsManifest from 'webpack-assets-manifest'
78

@@ -10,10 +11,9 @@ import { DEFAULT_OPTIONS, BUILD_BROWSER_BUNDLE_STAGE, PAGE_COUNT_WARN } from './
1011
import createRedirects from './create-redirects'
1112
import makePluginData from './plugin-data'
1213

13-
const assetsManifest = {}
14+
const assetsManifest: Record<string, unknown> = {}
1415

15-
/** @type {import("gatsby").GatsbyNode["pluginOptionsSchema"]} */
16-
export const pluginOptionsSchema = ({ Joi }: any) => {
16+
export const pluginOptionsSchema: GatsbyNode["pluginOptionsSchema"] = ({ Joi }) => {
1717
const MATCH_ALL_KEYS = /^/
1818

1919
// headers is a specific type used by Netlify: https://www.gatsbyjs.com/plugins/gatsby-plugin-netlify/#headers
@@ -41,9 +41,7 @@ export const pluginOptionsSchema = ({ Joi }: any) => {
4141
}
4242

4343
// Inject a webpack plugin to get the file manifests so we can translate all link headers
44-
/** @type {import("gatsby").GatsbyNode["onCreateWebpackConfig"]} */
45-
46-
export const onCreateWebpackConfig = ({ actions, stage }: any) => {
44+
export const onCreateWebpackConfig: GatsbyNode["onCreateWebpackConfig"] = ({ actions, stage }) => {
4745
// We only need to get manifest for production browser bundle
4846
if (stage !== BUILD_BROWSER_BUNDLE_STAGE) {
4947
return
@@ -59,8 +57,7 @@ export const onCreateWebpackConfig = ({ actions, stage }: any) => {
5957
})
6058
}
6159

62-
/** @type {import("gatsby").GatsbyNode["onPostBuild"]} */
63-
export const onPostBuild = async ({ store, pathPrefix, reporter }: any, userPluginOptions: any) => {
60+
export const onPostBuild: GatsbyNode["onPostBuild"] = async ({ store, pathPrefix, reporter }, userPluginOptions) => {
6461
const pluginData = makePluginData(store, assetsManifest, pathPrefix)
6562
const pluginOptions = { ...DEFAULT_OPTIONS, ...userPluginOptions }
6663

0 commit comments

Comments
 (0)