• Breve@pawb.social
    link
    fedilink
    arrow-up
    6
    ·
    edit-2
    9 months ago

    I guess it depends on your definition of “parse”, but let me tell you it’s still very painful to deal with things like attributes appearing in any order inside of a tag so I definitely am not advocating to use regex to “read” (or whatever you want to call it) HTML.

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

      My regex at work is full of (<[^>]+\s*){0,5} because we don’t care about 90 percent of the attributes. All we care is it’s class=“data I want” and eventually take me to that data.