Live data from Hacker News

Understand the JavaScript SEO basics

developers.google.com

21–30 of 61 posts

Re: Understand the JavaScript SEO basics

#21
post #18
post #8

Earlier quoted context omitted.

This is so out-of-touch with the modern web. Lots of totally legitimate websites, including major news outlets and Wikipedia, render their web pages on the client using JavaScript. Whether or not this is a good thing is a separate issue (personally I see nothing wrong with it), but it should be obvious that a useful search engine in 2019 needs to be able to index JavaScript-rendered content.

I, for one, would welcome a force with the size and influence of Google telling devs to cut the Javascript crap. To me, it’s like violating the conditional rendering rule: there are plausible reasons to want to do it, but Google is right to push back on it. It’s not as if totally legitimate websites don’t have reasonable technical alternatives here.

> I, for one, would welcome a force with the size and influence of Google telling devs to cut the JavaScript crap.

Wasn't this basically AMP though? The solution to the monster web developers were creating?

Re: Understand the JavaScript SEO basics

#22
This feels like such a smoke and mirrors thing. This gem:

Write compatible code

Browsers offer many APIs and JavaScript is a quickly-evolving language. Googlebot has some limitations regarding which APIs and JavaScript features it supports. To make sure your code is compatible with Googlebot, follow our guidelines for troubleshooting JavaScript problems.

Leads to this page:

https://developers.google.com/search/docs/guides/fix-search-...

Which says absolutely nothing. It details nothing about what is supported.

Utterly useless. No version of HTML running, no info about what gets run, no actual technical details at all.

Re: Understand the JavaScript SEO basics

#23
post #18

Earlier quoted context omitted.

I, for one, would welcome a force with the size and influence of Google telling devs to cut the Javascript crap. To me, it’s like violating the conditional rendering rule: there are plausible reasons to want to do it, but Google is right to push back on it. It’s not as if totally legitimate websites don’t have reasonable technical alternatives here.

> I, for one, would welcome a force with the size and influence of Google telling devs to cut the JavaScript crap. Wasn't this basically AMP though? The solution to the monster web developers were creating?

hackernews hates that too.

Re: Understand the JavaScript SEO basics

#24
post #9

A good search engine shouldn't process JS at all, and index only the content that is reachable via links pulled from HTML (which may, of course, be dynamic). The processing of JS explains a lot of the sheer garbage that is in the Google results. I think they do it because it ties into their business model. JS is needed to unearth the kind of crap that a certain segment of the user base is looking for. That certain se…

>A good search engine shouldn't process JS at all, and index only the content that is reachable via links pulled from HTML (which may, of course, be dynamic). A good search engine index based on what humans would consume.

JS doesn't ensure that; it is easily gamed to serve SEO rubbish to the spider, which is different from what it renders to a real user.

Re: Understand the JavaScript SEO basics

#25

SEO consultant here (yeah, yeah). Please, still in 2019, be careful with JavaScript unless you're willing to deal with a lot of uncertainty. Google routinely says how things are supposed to work, but there are plenty of examples where their crawlers act inconsistent to public statements. To be clear, probably not Googlebot's fault though; we as a species do a lot of weird things when building websites. Just finished…

> Server side render fixed a lot of this and rankings/traffic jumped.

Good, they should just delist client side rendered web pages.

Re: Understand the JavaScript SEO basics

#26
I echo what others like @sharkweek are saying - Google has been saying that they index JavaScript for quite a while now. At I/O 2019 they said the crawler should be on the latest Chromium codebase that supports all modern JavaScript features. I built some test cases [0] to see if this is true, and just couldn't get Google to index content inserted via JavaScript. For example, scroll down to the Popover button test case.

Maybe I'm doing something wrong? Open to feedback. Opensourced code is here [1].

[0]https://shan.io/will-it-index/

[1]https://github.com/rayshan/rayshan.github.io/tree/master/wil...

Re: Understand the JavaScript SEO basics

#27

SEO consultant here (yeah, yeah). Please, still in 2019, be careful with JavaScript unless you're willing to deal with a lot of uncertainty. Google routinely says how things are supposed to work, but there are plenty of examples where their crawlers act inconsistent to public statements. To be clear, probably not Googlebot's fault though; we as a species do a lot of weird things when building websites. Just finished…

> Server side render fixed a lot of this and rankings/traffic jumped. Good, they should just delist client side rendered web pages.

While I love to rag on SPAs as much as the next person, doing that is ripe for antitrust. "They're trying to force the web to look like what they want"

Re: Understand the JavaScript SEO basics

#28
A little off-topic, but one of the most exciting things in my mind about Phoenix LiveView [1] is that you can get some dynamic web applications and not have to navigate this JS-rendering minefield. When a LiveView page is request, the server sends over the full page as just static HTML. The JS half of LiveView then upgrades to a websocket connection, and your page becomes dynamic.

Not a good fit for everything, but it's great if you want to add some fancy form validation to, say, your landing page. You can render whatever you want with LiveView, get your fancy dynamic stuff, without having to worry about making your page more indexable.

[1]: https://github.com/phoenixframework/phoenix_live_view

Re: Understand the JavaScript SEO basics

#30
post #19

A good search engine shouldn't process JS at all, and index only the content that is reachable via links pulled from HTML (which may, of course, be dynamic). The processing of JS explains a lot of the sheer garbage that is in the Google results. I think they do it because it ties into their business model. JS is needed to unearth the kind of crap that a certain segment of the user base is looking for. That certain se…

I quit catering to users who don't run JS a decade ago "nobody in their right mind" would expect to use the web in the last 15 years or so with JS disabled and have it actually work

To add to this: when a client comes to my employer, if it is required to work without Javascript it is the norm for that to be explicitly specified. Just to add to this point. It’s otherwise assumed not to be an issue
Post reply on HN