[PR #978] [MERGED] fix: support experimental.outputHashSalt config and NEXT_HASH_SALT env var #996

Closed
opened 2026-05-06 13:11:28 +02:00 by BreizhHardware · 0 comments

📋 Pull Request Information

Original PR: https://github.com/cloudflare/vinext/pull/978
Author: @Divkix
Created: 4/30/2026
Status: Merged
Merged: 5/1/2026
Merged by: @james-elicx

Base: mainHead: fix/754-output-hash-salt


📝 Commits (5)

  • ce767ac fix: support experimental.outputHashSalt config and NEXT_HASH_SALT env var (#754)
  • c2f158b ci: re-trigger CI (Windows create-next-app flake, STATUS_STACK_BUFFER_OVERRUN)
  • 3addb04 fix: use augmentChunkHash for outputHashSalt instead of output.hashSalt
  • 2a244ea Merge branch 'main' into fix/754-output-hash-salt
  • c28f71a refactor: simplify hash-salt plugin comments

📊 Changes

4 files changed (+85 additions, -0 deletions)

View changed files

📝 packages/vinext/src/check.ts (+4 -0)
📝 packages/vinext/src/config/next-config.ts (+14 -0)
📝 packages/vinext/src/index.ts (+17 -0)
📝 tests/next-config.test.ts (+50 -0)

📄 Description

Fixes #754

Summary

  • Add hashSalt to ResolvedNextConfig, computed as concatenation of experimental.outputHashSalt config + NEXT_HASH_SALT env var
  • Inject hashSalt into Rollup/Rolldown client build output via output.hashSalt option
  • Pass nextConfig.hashSalt to getClientOutputConfigForVite() in all client build paths

Test plan

  • 6 new unit tests in tests/next-config.test.ts covering: default (no salt), config-only, env-only, concatenation, env-without-config

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/cloudflare/vinext/pull/978 **Author:** [@Divkix](https://github.com/Divkix) **Created:** 4/30/2026 **Status:** ✅ Merged **Merged:** 5/1/2026 **Merged by:** [@james-elicx](https://github.com/james-elicx) **Base:** `main` ← **Head:** `fix/754-output-hash-salt` --- ### 📝 Commits (5) - [`ce767ac`](https://github.com/cloudflare/vinext/commit/ce767ac0051000ec6c54518e7bbf5ab3dd18e3b7) fix: support experimental.outputHashSalt config and NEXT_HASH_SALT env var (#754) - [`c2f158b`](https://github.com/cloudflare/vinext/commit/c2f158b84b5c00e61b9f5661e52714ffdfb11da2) ci: re-trigger CI (Windows create-next-app flake, STATUS_STACK_BUFFER_OVERRUN) - [`3addb04`](https://github.com/cloudflare/vinext/commit/3addb04e64a47c3bdcac2eab65901c83ef1d630d) fix: use augmentChunkHash for outputHashSalt instead of output.hashSalt - [`2a244ea`](https://github.com/cloudflare/vinext/commit/2a244ea16229e6aa2c4e0042f5945d39be81b737) Merge branch 'main' into fix/754-output-hash-salt - [`c28f71a`](https://github.com/cloudflare/vinext/commit/c28f71aaffefda57eba0772b4126ca7a0bfdffae) refactor: simplify hash-salt plugin comments ### 📊 Changes **4 files changed** (+85 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `packages/vinext/src/check.ts` (+4 -0) 📝 `packages/vinext/src/config/next-config.ts` (+14 -0) 📝 `packages/vinext/src/index.ts` (+17 -0) 📝 `tests/next-config.test.ts` (+50 -0) </details> ### 📄 Description Fixes #754 ## Summary - Add hashSalt to ResolvedNextConfig, computed as concatenation of experimental.outputHashSalt config + NEXT_HASH_SALT env var - Inject hashSalt into Rollup/Rolldown client build output via output.hashSalt option - Pass nextConfig.hashSalt to getClientOutputConfigForVite() in all client build paths ## Test plan - 6 new unit tests in tests/next-config.test.ts covering: default (no salt), config-only, env-only, concatenation, env-without-config --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
BreizhHardware 2026-05-06 13:11:28 +02:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/vinext#996
No description provided.