From: Ori Livneh Date: Wed, 12 Aug 2015 15:52:39 +0000 (-0700) Subject: Output stylesheet links before other link elements in X-Git-Tag: 1.31.0-rc.0~10448 X-Git-Url: https://git.cyclocoop.org/%28%28?a=commitdiff_plain;h=bb0f0a485d17f7fae25fb49f278f7d17cb576c71;p=lhc%2Fweb%2Fwiklou.git Output stylesheet links before other link elements in Since external CSS is render-blocking, it should be discoverable to the browser as soon as possible. So move it up to the top of . Change-Id: I68a6cce2f33ceb7f6461fcbb7323ae13c413aa89 --- diff --git a/includes/OutputPage.php b/includes/OutputPage.php index 26f9efad5a..d694e581f4 100644 --- a/includes/OutputPage.php +++ b/includes/OutputPage.php @@ -2703,11 +2703,12 @@ class OutputPage extends ContextSource { $ret .= Html::element( 'title', null, $this->getHTMLTitle() ) . "\n"; + $ret .= $this->buildCssLinks() . "\n"; + foreach ( $this->getHeadLinksArray() as $item ) { $ret .= $item . "\n"; } - $ret .= $this->buildCssLinks() . "\n"; $ret .= $this->getHeadScripts() . "\n"; foreach ( $this->mHeadItems as $item ) {