slimic / yii2-showloading
Yii2 extension for showLoading jQuery plugin
Installs: 8
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
Language:JavaScript
Type:yii2-extension
Requires
- yiisoft/yii2: *
This package is not auto-updated.
Last update: 2024-03-23 13:06:19 UTC
README
Installation
Composer
Simply add extension to your composer.json:
{ "require": { "slimic960/yii2-showloading": "*" } }
After this just update your dependencies as usual, e.g. by running composer update
##Configuration
To make the plugin work you just need to register asset bundle. Either specify it as a dependency, or register directly in your view like this:
use slimic960\showloading\ShowLoadingAsset; ShowLoadingAsset::register($this);
##Sample usage
To show / hide loading indicator, simply call showLoading()
/ hideLoading()
methods:
$('#my-content-panel-id').showLoading(); $('#my-content-panel-id').hideLoading();