Earlier quoted context omitted.
> JS can introduce more dynamic HTML, but view-source should always represent any non-redirected HTTP response That is both true and false. Because the JS can introduce dynamic content, the source returned by the HTTP response often doesn't match the source that is rendered by the browser itself. In many cases, a site will return a skeleton (just HTML) and then make an Ajax request to populate it. In my case, it was…
But we're not talking about the rendered source here. We're talking about "view source", which afaik always matches what is returned by the server. The post replied to claims that Nokogiri doesn't see this however so I'm puzzled.
That's also the reason while you had to "pre-render" you javascript web apps for SEO purposes until google bot got the ability to execute javascript.