2

I have this user case where we render Angular 2 app on the server for Google to be able to see the DOM.

It is all good with indexing, but I doubt that html tags are good for SEO. I have structure like this:

<body>
   <my-app></my-app>
</body>

Is this valid for the crawler? Is this going to affect my rating as a whole?

If the HTML custom elements are endangering your ranking, can you even use Angular 2 or any shadow DOM at all?

1

When you use a custom element, that will be an element search engines will be unable to know its semantics. So it will not help with SEO at all.

The way to get around that is to use microformats to identify the content of those elements, or the content overall, using schema.org, JSON-LD and all those various vocabularies, attributes and properties.

With those, the semantics of the HTML elements are not as important since they will be identified with the vocabularies of schema or whichever other vocabulary you use.

  • Thank you.Can I ask since it is not going to help, is it going to hurt? How big of an effect something like this can have, can it be measured? – Sotir.ls Nov 29 '16 at 14:38
  • It can't hurt in that search engines will handle it just like any other unknown text content. They may use context of where it is placed to try and determine what it is about, or the text itself, but we would have no way of knowing how they would handle that. I'm not sure how it can be measured if at all. – Rob Nov 29 '16 at 15:54
  • That is very interesting. Server rendering is suppose to solve the problem and make SPA's the solution when it comes to creating a nice website. Since google pay attention at the speed, nothing beats the speed of a SPA, but yet Angular requires to use shadow DOM and custom elements, that are not yet clear from SEO perspective. Also not every SPA is behind authentication (where google cant go) how do you sell Angular to the management as a good development practice... – Sotir.ls Nov 30 '16 at 10:54
  • Thanks Rob, will do some prove of concept and see if there is a working solution. – Sotir.ls Nov 30 '16 at 10:55
  • Personally, I treat Angular, and any similar things, like the plague. It's something for large companies that have time and money to waste on but mine doesn't waste time or money. – Rob Nov 30 '16 at 10:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.