turva-llms-txt-validator 0.1.7 → 0.1.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/index.mjs +1 -1
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "turva-llms-txt-validator",
3
- "version": "0.1.7",
3
+ "version": "0.1.8",
4
4
  "description": "Validate a site's llms.txt structure: eight checks, pass/warn/fail, JSON output. Same checks as the hosted validator at turva.dev/llms-txt-validator.",
5
5
  "type": "module",
6
6
  "main": "./src/index.mjs",
package/src/index.mjs CHANGED
@@ -148,7 +148,7 @@ export function validateLlmsTxt(f) {
148
148
  } else {
149
149
  add("sections", "warn", "H2 sections group the content", "no H2 sections found; sections are the convention for grouping links");
150
150
  }
151
- const links = [...f.text.matchAll(/\[([^\][]*)\]\(([^)\s]+)\)/g)];
151
+ const links = [...f.text.matchAll(/\[([^\][]*)\]\(([^)\s]{1,2048})\)/g)];
152
152
  const absolute = links.filter((m) => /^https?:\/\//.test(m[2])).length;
153
153
  if (links.length === 0) {
154
154
  add("links", "warn", "Markdown links an agent can follow", "no markdown links found");