···11+---
22+maudit: patch
33+---
44+55+Revert Tailwind hashing change, need a different solution. In the meantime, it is possible for stale content to appear with Tailwind in select conditions.
-5
crates/maudit/src/assets.rs
···346346 }
347347 HashAssetType::Style(opts) => {
348348 buf.push(opts.tailwind as u8);
349349-350350- if opts.tailwind {
351351- // If Tailwind is enabled for that style, we can't calculate the hash purely from the file content, as the final output will depend on the Tailwind configuration and the content of the entire project. So we'll add a random thing to the hash to ensure always a new hash. The way to fix this would be to calculate the hash based on the final output CSS after Tailwind processing, but that'd require holding a lot of pages in memory, transforming after we're done with bundling all assets, etc. Which: Does not feel good. Until a better solution, the hash changing on each build when Tailwind is involved will have to do.
352352- buf.extend_from_slice(&Instant::now().elapsed().as_nanos().to_le_bytes());
353353- }
354349 }
355350 HashAssetType::Script => { /* No extra options for scripts yet */ }
356351 }