InsightsWidgetAsset   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 25
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 9
dl 0
loc 25
rs 10
c 0
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A init() 0 20 1
1
<?php
2
namespace dukt\facebook\web\assets\insightswidget;
3
4
use craft\web\AssetBundle;
5
use craft\web\assets\cp\CpAsset;
6
7
/**
8
 * Insights widget asset bundle.
9
 *
10
 * @author Dukt <[email protected]>
11
 * @since  2.0
12
 */
13
class InsightsWidgetAsset extends AssetBundle
14
{
15
    /**
16
     * @inheritdoc
17
     */
18
    public function init()
19
    {
20
        $this->sourcePath = __DIR__.'/dist';
21
22
        // define the dependencies
23
        $this->depends = [
24
            CpAsset::class,
25
        ];
26
27
        // define the relative path to CSS/JS files that should be registered with the page
28
        // when this asset bundle is registered
29
        $this->js = [
30
            'InsightsWidget.js',
31
        ];
32
33
        $this->css = [
34
            'insights-widget.css',
35
        ];
36
37
        parent::init();
38
    }
39
}