Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compress render HTML #4284

Closed
imtaotao opened this issue Dec 5, 2024 · 1 comment
Closed

Compress render HTML #4284

imtaotao opened this issue Dec 5, 2024 · 1 comment

Comments

@imtaotao
Copy link

imtaotao commented Dec 5, 2024

Is it possible to compress when generating HTML?

// For example

import { load } from 'cheerio';

const $ = load(`<div></div>`)

$.root().html({
  compress: true,
})
@fb55
Copy link
Member

fb55 commented Dec 25, 2024

Compressing HTML can be complex, and there are separate projects that implement this (eg. terser). You can add them on as a secondary step.

@fb55 fb55 closed this as not planned Won't fix, can't repro, duplicate, stale Dec 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants