summaryrefslogtreecommitdiff
path: root/app/views/layouts/_head.html.haml
diff options
context:
space:
mode:
authorTim Zallmann <tzallmann@gitlab.com>2018-07-26 15:00:18 +0000
committerClement Ho <clemmakesapps@gmail.com>2018-07-26 15:00:18 +0000
commitf7ac5384258f02fc2f4da681338f928a5363b19c (patch)
tree7f675aba4cd25e505856f6095df48d72159a4f08 /app/views/layouts/_head.html.haml
parent2fbafe1a41f846a5fd6a58d27f9fb16484edb070 (diff)
downloadgitlab-ce-f7ac5384258f02fc2f4da681338f928a5363b19c.tar.gz
DNS Prefetching + Preconnect of assets_host (CDN Domain)
Diffstat (limited to 'app/views/layouts/_head.html.haml')
-rw-r--r--app/views/layouts/_head.html.haml5
1 files changed, 5 insertions, 0 deletions
diff --git a/app/views/layouts/_head.html.haml b/app/views/layouts/_head.html.haml
index 9253a0652da..ac5916d129c 100644
--- a/app/views/layouts/_head.html.haml
+++ b/app/views/layouts/_head.html.haml
@@ -3,6 +3,11 @@
- site_name = "GitLab"
%head{ prefix: "og: http://ogp.me/ns#" }
%meta{ charset: "utf-8" }
+
+ - if Feature.enabled?('asset_host_prefetch') && ActionController::Base.asset_host
+ %link{ rel: 'dns-prefetch', href: ActionController::Base.asset_host }
+ %link{ rel: 'preconnnect', href: ActionController::Base.asset_host, crossorigin: '' }
+
%meta{ 'http-equiv' => 'X-UA-Compatible', content: 'IE=edge' }
-# Open Graph - http://ogp.me/