dynamic title and description are not evaluated in Google search

8 views
Skip to first unread message

gianluca de vecchi

unread,
Jan 17, 2017, 11:38:28 AM1/17/17
to Angular
Hello,
My website is built on AngularJs, and Google search is able to index it fine and the fetch takes all the pages properly. It is a Single Page application so the titles as well as the meta descriptions are dynamic. If I peer through firebug in the pages title and description are fine and correctly evaluated, but for some reason the indexed pages in the google search are displayed with the Angular expression still to be evaluated.
This is the code in the head, inspecting by firebug values are correctly there:
<title ng-bind='applicationCtrl.applicationService.title'></title>
<meta name='description' content='{{applicationCtrl.applicationService.description}}'>
And this is what I get in the google search for description :

{{applicationCtrl.applicationService.description}}

Could you give me an hint about how to fix it?
Many thanks

Sander Elias

unread,
Jan 18, 2017, 12:00:09 AM1/18/17
to Angular
Hi Gianluca,

My guess is that google starts analysing your page, before your scripts are run. The simplest solution I see is, use a small Server-side solution to fill those two on the server side. I'm not aware of a way to tell google analytics you updated the page title and meta tags.

Regards
Sander
Reply all
Reply to author
Forward
0 new messages