Skip to content

fix(void): avoid rewriting unchanged generated files - #215

Merged
cpojer merged 1 commit into
mainfrom
fix/write-generated-files-if-changed
Jun 8, 2026
Merged

cpojer merged 1 commit into
mainfrom
fix/write-generated-files-if-changed

Conversation

@TheAlexLichter

@TheAlexLichter TheAlexLichter commented Jun 7, 2026 •

Copy link
Copy Markdown
Member

I was a bit surprised when my MacBook turned hot after a while of running multiple VS Code windows with Void apps.

The reason is that Void rn rewrites tsconfigs again even if the content is the same, triggering other extensions such as Tailwind.

This PR only rewrites the file when the content actually changes.

(Netlify CI fails due to the site being on void)

@netlify

netlify Bot commented Jun 7, 2026 •

Copy link
Copy Markdown

❌ Deploy Preview for staging-void-cloud failed.

Name Link
🔨 Latest commit c075ef3
🔍 Latest deploy log https://app.netlify.com/projects/staging-void-cloud/deploys/6a25dbd3fcb63e000889c3a6

@TheAlexLichter
TheAlexLichter requested a review from cpojer June 7, 2026 21:02

@cpojer cpojer left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Nice!

@cpojer
cpojer merged commit 45919c5 into main Jun 8, 2026
6 of 10 checks passed
@cpojer
cpojer deleted the fix/write-generated-files-if-changed branch June 8, 2026 02:24
cpojer pushed a commit that referenced this pull request Sep 11, 2026
…ype (#215)

* fix(dispatch): serve correct content-type for .md and re-derive stored octet-stream

Add md/markdown/yaml/yml/toml to the MIME table, and treat a stored
application/octet-stream as unknown so it is re-derived from the path at
serve time. Content-addressed assets are never re-uploaded, so this heals
already-deployed files (e.g. viteplus.dev .md pages) without a redeploy.

* refactor(dispatch): fold application/null sentinel into resolveAssetContentType

Return string | undefined from the resolver so the 'omit Content-Type
header' decision lives in one place, collapsing the three duplicated
`contentType !== 'application/null'` guards at the call sites to a plain
`if (contentType)`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants