chore(bootstrap.php): separately minify php when files are requested

This commit is contained in:
Cory Dransfeldt 2025-06-15 11:32:01 -07:00
parent 2b22d10b46
commit 320f5e53db
No known key found for this signature in database
6 changed files with 259 additions and 14 deletions

View file

@ -2,7 +2,7 @@ import htmlmin from 'html-minifier-terser';
export const htmlConfig = (eleventyConfig) => {
eleventyConfig.addTransform('html-minify', (content, path) => {
if (path && (path.endsWith('.html') || path.endsWith('.php'))) {
if (path && path.endsWith('.html')) {
return htmlmin.minify(content, {
collapseBooleanAttributes: true,
collapseWhitespace: true,