Skip to content

Commit bca3249

Browse files
ref(ts): Marginally improve types on onCreateWebpackConfig (#7329)
1 parent b07da30 commit bca3249

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/gatsby/onCreateWebpackConfig.ts

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,9 @@
44
import path from 'path';
55

66
import {sentryWebpackPlugin} from '@sentry/webpack-plugin';
7+
import {GatsbyNode} from 'gatsby';
78

8-
function main({actions}) {
9+
const onCreateWebpackConfig: GatsbyNode['onCreateWebpackConfig'] = ({actions}) => {
910
actions.setWebpackConfig({
1011
resolve: {
1112
fallback: {
@@ -25,6 +26,6 @@ function main({actions}) {
2526
}),
2627
],
2728
});
28-
}
29+
};
2930

30-
export default main;
31+
export default onCreateWebpackConfig;

0 commit comments

Comments
 (0)