Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/nice-apples-burn.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@react-router/serve": patch
---

disable compression for RSC responses for now
6 changes: 5 additions & 1 deletion packages/react-router-serve/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,11 @@ async function run() {

let app = express();
app.disable("x-powered-by");
app.use(compression());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it be easier/less risk of impacting non-RSC use cases to just disable it completely for RSC framework mode for now because it's unstable?

  if (!isRSCServerBuild(build)) {
    app.use(compression());
  }

I assume we'll want to turn it back on before stabilizing so then we can just remove the if and not unwind these other changes?


if (!isRSCServerBuild(build)) {
app.use(compression());
}

app.use(
path.posix.join(build.publicPath, "assets"),
express.static(path.join(build.assetsBuildDirectory, "assets"), {
Expand Down