Magpie HTML - v0.2.3
    Preparing search index...

    Function extractRobots

    • Extract robots metadata from HTML.

      Parameters

      Returns RobotsMetadata

      Robots metadata

      Extracts robot directives from meta tags for general robots, Googlebot, Bingbot, and Google News bot.

      // With parsed document (recommended for multiple extractions)
      const doc = parseHTML(htmlString);
      const robots = extractRobots(doc);

      // Or directly with HTML string
      const robots = extractRobots(htmlString);