Skip to content

Commit

Permalink
fix: html_size, images_without_alt was empty
Browse files Browse the repository at this point in the history
  • Loading branch information
popstas committed Apr 4, 2024
1 parent ad1dcb3 commit 910986c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/scrap-site.js
Original file line number Diff line number Diff line change
Expand Up @@ -302,13 +302,13 @@ async function scrapSite ({baseUrl, options = {}}) {
dom_size: document.getElementsByTagName('*').length,
head_size: document.head.innerHTML.length,
body_size: document.body.innerHTML.length,
html_size_rendered: document.head.innerHTML.length +
document.body.innerHTML.length,
html_size: document.head.innerHTML.length +
document.body.innerHTML.length, // TODO: it's doesn't work
text_ratio_percent: Math.round(
document.body.innerText.length / document.body.innerHTML.length *
100),
images: $('img').length,
images_without_alt: $('img:not([alt]').length,
images_without_alt: $('img:not([alt])').length,
images_alt_empty: $('img[alt=""]').length,
images_outer: $(
'img[src^="http"]:not([src^="/"]):not([src*="' + domain2level +
Expand Down

0 comments on commit 910986c

Please sign in to comment.