• Breve@pawb.social
    link
    fedilink
    arrow-up
    3
    ·
    9 months ago

    Yes, I said in my original comment that it can’t universally parse and validate every HTML document. If they’re older pages that don’t do lots of crazy formatting then it’s not too hard to use regex as a first pass then take a second pass through the results to weed out the odd stuff.

    • hperrin@lemmy.world
      link
      fedilink
      arrow-up
      9
      ·
      edit-2
      9 months ago

      I would argue that that is not parsing. That’s just pattern matching. For something to be parsing a document, it would have to have some “understanding” of the structure of the document. Since regex is not powerful enough to correctly “understand” the document, it’s not parsing.