DEV: Add site description to crawler homepage view (#32845)

In some cases, Google crawlers don't output the meta description but
rather they output the first bit of text in the UI. Sometimes that is a
mix of table headings, topic titles and excerpts, which don't reflect
the site's mission. Adding the description to the homepage header might
help.

Internal ticket t/154372
This commit is contained in:
Penar Musaraj
2025-05-21 18:33:59 -04:00
committed by GitHub
parent b3a39ccdf6
commit 2b6efa56f3
4 changed files with 35 additions and 4 deletions

View File

@ -80,6 +80,7 @@ class ApplicationController < ActionController::Base
CrawlerDetection.crawler?(request.user_agent, request.headers["HTTP_VIA"])
)
end
helper_method :use_crawler_layout?
def perform_refresh_session
refresh_session(current_user) unless @readonly_mode