Class kartik\base\AssetBundle

Inheritancekartik\base\AssetBundle » yii\web\AssetBundle
Subclasseskartik\base\AnimateAsset, kartik\base\Html5InputAsset, kartik\base\PluginAssetBundle, kartik\base\WidgetAsset, kartik\form\ActiveFormAsset, kartik\select2\Select2Asset, kartik\select2\ThemeBootstrapAsset, kartik\select2\ThemeClassicAsset, kartik\select2\ThemeDefaultAsset, kartik\select2\ThemeKrajeeAsset, kartik\tree\TreeViewAsset, kartik\tree\TreeViewInputAsset
Available since version1.0

Base asset bundle used for all Krajee extensions.

Public Methods

Hide inherited methods

MethodDescriptionDefined By
addLanguage() Adds a language JS locale file kartik\base\AssetBundle
init() kartik\base\AssetBundle

Protected Methods

Hide inherited methods

MethodDescriptionDefined By
setSourcePath() Sets the source path if empty kartik\base\AssetBundle
setupAssets() Set up CSS and JS asset arrays based on the base-file names kartik\base\AssetBundle

Constants

Hide inherited constants

ConstantValueDescriptionDefined By
EMPTY_ASSET 'N0/@$$3T$' Unique value to set an empty asset via Yii AssetManager configuration. kartik\base\AssetBundle
EMPTY_PATH 'N0/P@T#' Unique value to set an empty asset file path via Yii AssetManager configuration. kartik\base\AssetBundle
KRAJEE_ASSET 'K3/@$$3T$' Unique value identifying a Krajee asset kartik\base\AssetBundle
KRAJEE_PATH 'K3/P@T#' Unique value identifying a Krajee asset file path kartik\base\AssetBundle

Property Details

$css public property
public $css self::KRAJEE_ASSET
$depends public property
public $depends = ['yii\web\JqueryAsset''yii\bootstrap\BootstrapAsset']
$js public property
public $js self::KRAJEE_ASSET
$sourcePath public property
public $sourcePath self::KRAJEE_PATH

Method Details

addLanguage() public method

Adds a language JS locale file

public kartik\base\AssetBundle addLanguage ( $lang '', $prefix '', $dir null, $min false )
$lang string

The ISO language code

$prefix string

The language locale file name prefix

$dir string

The language file directory relative to source path

$min bool

Whether to auto use minified version

return kartik\base\AssetBundle

Instance

init() public method

public void init ( )
setSourcePath() protected method

Sets the source path if empty

protected void setSourcePath ( $path )
$path string

The path to be set

setupAssets() protected method

Set up CSS and JS asset arrays based on the base-file names

protected void setupAssets ( $type, $files = [] )
$type string

Whether 'css' or 'js'

$files array

The list of 'css' or 'js' basefile names