minimalcss: Slow when HTML + CSS is large

When I run:

▶ time node bin/minimalcss.js https://www.peterbe.com/plog-original.html -o /dev/null

It steadily takes about 6-7 seconds. That’s way too slow. Let’s see what we can do.

About this issue

  • Original URL
  • State: open
  • Created 6 years ago
  • Comments: 21 (15 by maintainers)

Commits related to this issue

Most upvoted comments

That’s soo cool. I’d love to experiment with making minimalcss depend on DropCSS. I love the idea of how minimalcss can get you the rendered DOM as a HTML string, including any DOM mutations (first) by things like window.onload but once it has the HTML strings (per URL) and the CSS hrefs, technically it could replace csstree+cheerio if it works out.

what would be the value-add of --use-dropcss over the DropCSS/Puppeteer demo i posted above and the same advice in its docs? if you’d like to add this option to minimalcss, then certainly feel free to do so.

Hint hint @leeoniya ^ 😃

i’m not sure i got this one 😃 did you want me to compare the diff between dropcss and minimalcss outputs of your site?