Skip to content

Commit bbc3ce0

Browse files
committed
fix: set next build id to commit hash
1 parent 99f26b1 commit bbc3ce0

3 files changed

Lines changed: 11 additions & 0 deletions

File tree

next.config.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
// @ts-check
22

3+
const nextBuildId = require("next-build-id")
4+
35
const shouldAnalyzeBundles = process.env.ANALYZE === "true"
46

57
/** @type { import('next').NextConfig } */
@@ -29,6 +31,7 @@ let nextConfig = {
2931
},
3032
]
3133
},
34+
generateBuildId: () => nextBuildId({ dir: __dirname }),
3235
}
3336

3437
if (shouldAnalyzeBundles) {

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,7 @@
124124
"eslint-plugin-promise": "^6.1.1",
125125
"eslint-plugin-react": "^7.32.2",
126126
"eslint-plugin-tailwind": "^0.2.1",
127+
"next-build-id": "^3.0.0",
127128
"prettier": "^2.8.3",
128129
"serve": "^14.1.2",
129130
"stylelint": "^14.16.1",

pnpm-lock.yaml

Lines changed: 7 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)