Commit b3e4096c39bb4f9c02ed8a269304f92a8fcccce6

Authored by Anastasia
1 parent 95fc39b2

page speed

frontend/assets/AppAsset.php
@@ -13,7 +13,7 @@ @@ -13,7 +13,7 @@
13 public $baseUrl = '@web'; 13 public $baseUrl = '@web';
14 public $css = [ 14 public $css = [
15 'css/style.css', 15 'css/style.css',
16 - '//fonts.googleapis.com/css?family=Ubuntu:400,500,700&subset=cyrillic,cyrillic-ext,latin-ext' 16 +// '//fonts.googleapis.com/css?family=Ubuntu:400,500,700&subset=cyrillic,cyrillic-ext,latin-ext'
17 ]; 17 ];
18 public $js = [ 18 public $js = [
19 'js/script.js', 19 'js/script.js',
frontend/views/layouts/main.php
@@ -86,6 +86,22 @@ @@ -86,6 +86,22 @@
86 <!DOCTYPE html > 86 <!DOCTYPE html >
87 <html xmlns="http://www.w3.org/1999/html" xmlns="http://www.w3.org/1999/html" lang="<?= \Yii::$app->language ?>"> 87 <html xmlns="http://www.w3.org/1999/html" xmlns="http://www.w3.org/1999/html" lang="<?= \Yii::$app->language ?>">
88 <head> 88 <head>
  89 +
  90 + <script type="text/javascript">
  91 + WebFontConfig = {
  92 + google: {families: [ 'Ubuntu:400,500,700' ]}
  93 + };
  94 + (function() {
  95 + var wf = document.createElement('script');
  96 + wf.src = ('https:' == document.location.protocol ? 'https' : 'http') + '://ajax.googleapis.com/ajax/libs/webfont/1.5.18/webfont.js';
  97 + wf.type = 'text/javascript';
  98 + wf.async = 'true';
  99 + var s = document.getElementsByTagName('script')[ 0 ];
  100 + s.parentNode.insertBefore(wf, s);
  101 + })(); </script>
  102 +
  103 + <script>
  104 +
89 <!-- Global site tag (gtag.js) - Google Analytics --> 105 <!-- Global site tag (gtag.js) - Google Analytics -->
90 <script async src="https://www.googletagmanager.com/gtag/js?id=UA-120861020-1"></script> 106 <script async src="https://www.googletagmanager.com/gtag/js?id=UA-120861020-1"></script>
91 <script> 107 <script>
frontend/views/site/index.php
@@ -76,7 +76,7 @@ JS; @@ -76,7 +76,7 @@ JS;
76 <!--размер img 1920x556--> 76 <!--размер img 1920x556-->
77 <?=ImageHelper::set($slide->language->image->getPath()) 77 <?=ImageHelper::set($slide->language->image->getPath())
78 ->cropResize(1920, 556) 78 ->cropResize(1920, 556)
79 - ->quality(84) 79 + ->quality(82)
80 ->renderImage()?> 80 ->renderImage()?>
81 </a> 81 </a>
82 </div> 82 </div>
@@ -98,7 +98,7 @@ JS; @@ -98,7 +98,7 @@ JS;
98 <!--263x146px--> 98 <!--263x146px-->
99 <?=ImageHelper::set($service->image->getPath()) 99 <?=ImageHelper::set($service->image->getPath())
100 ->cropResize(263, 146) 100 ->cropResize(263, 146)
101 - ->quality(84) 101 + ->quality(82)
102 ->renderImage()?> 102 ->renderImage()?>
103 </div> 103 </div>
104 <div class="style categories-home-links-wr"> 104 <div class="style categories-home-links-wr">
@@ -164,11 +164,11 @@ JS; @@ -164,11 +164,11 @@ JS;
164 <a href="<?=Url::to(['alias' => $item->language->alias])?>"> 164 <a href="<?=Url::to(['alias' => $item->language->alias])?>">
165 <div class="img"><?=ImageHelper::set(($item->image) ? $item->image->getPath() : null) 165 <div class="img"><?=ImageHelper::set(($item->image) ? $item->image->getPath() : null)
166 ->cropResize(388, 240) 166 ->cropResize(388, 240)
167 - ->quality(84) 167 + ->quality(82)
168 ->renderImage()?></div> 168 ->renderImage()?></div>
169 <div class="rotate"><?=ImageHelper::set(($item->image) ? $item->image->getPath() : null) 169 <div class="rotate"><?=ImageHelper::set(($item->image) ? $item->image->getPath() : null)
170 ->cropResize(388, 240) 170 ->cropResize(388, 240)
171 - ->quality(84) 171 + ->quality(82)
172 ->renderImage()?></div> 172 ->renderImage()?></div>
173 <p><?=$item->title?></p> 173 <p><?=$item->title?></p>
174 <span class="btn_"><?=\Yii::t('app','Buy')?></span> 174 <span class="btn_"><?=\Yii::t('app','Buy')?></span>