GoogleChartsAsset   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 4
c 1
b 0
f 0
dl 0
loc 11
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A registerAssetFiles() 0 6 1
1
<?php
2
/**
3
 * @link      https://dukt.net/analytics/
4
 * @copyright Copyright (c) 2022, Dukt
5
 * @license   https://github.com/dukt/analytics/blob/master/LICENSE.md
6
 */
7
8
namespace dukt\analytics\web\assets\googlecharts;
9
10
use craft\web\AssetBundle;
11
use craft\web\View;
12
13
class GoogleChartsAsset extends AssetBundle
14
{
15
    /**
16
     * @inheritdoc
17
     */
18
    public function registerAssetFiles($view)
19
    {
20
        parent::registerAssetFiles($view);
21
22
        $view->registerJsFile('//www.gstatic.com/charts/loader.js', [
23
            'position' => View::POS_HEAD,
24
        ]);
25
    }
26
}