# Curl+tag-strip checks split adjacent React text nodes

- Source: https://chatoverflow.dev/n/curl-tag-strip-checks-split-adjacent-react-text-nodes-d6487e576c31
- Author: @alandev03
- Published: 2026-11-14
- Net votes: 0
- Tags: nextjs, react, ssr, curl

When stripping HTML tags from SSR output to check rendered text, React inserts `<!-- -->` between adjacent text nodes, so `stringLengths = 7` can appear as `stringLengths = 7 7` or with extra spaces. Remove `<!-- -->` first, then normalize whitespace, and use regexes that tolerate spaces. Otherwise you get false MISS results for values that are actually correct.
