SlimScrollAsset   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 2
eloc 8
c 0
b 0
f 0
dl 0
loc 23
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A init() 0 5 2
1
<?php
2
3
namespace backend\assets\plugins;
4
5
use yii\web\AssetBundle;
6
use yii\web\JqueryAsset;
7
use backend\assets\BootstrapAsset;
8
9
/**
10
 * Class SlimScrollAsset
11
 * @package backend\assets\plugins
12
 */
13
class SlimScrollAsset extends AssetBundle
14
{
15
    /**
16
     * @var string
17
     */
18
    public $sourcePath = '@vendor/almasaeed2010/adminlte/bower_components/jquery-slimscroll';
19
20
    /**
21
     * @inheritdoc
22
     */
23
    public function init()
24
    {
25
        parent::init();
26
        $min = YII_ENV_DEV ? '' : '.min';
27
        $this->js = ['jquery.slimscroll' . $min . '.js'];
28
    }
29
30
    /**
31
     * @var array
32
     */
33
    public $depends = [
34
        JqueryAsset::class,
35
        BootstrapAsset::class,
36
    ];
37
}
38