Gridster.js widget for Yii2

Installs: 2 146

Dependents: 0

Suggesters: 0

Security: 0

Stars: 6

Watchers: 2

Forks: 3

Open Issues: 0


v2.0.1 2015-04-28 02:51 UTC

This package is not auto-updated.

Last update: 2024-05-25 15:34:33 UTC


This extension provides the Gridster.js integration for the Yii2 framework.

Latest Stable Version Total Downloads Latest Unstable Version License


The preferred way to install this extension is through composer.

Either run

php composer.phar require --prefer-dist fedemotta/yii2-gridster "*"

or add

"fedemotta/yii2-gridster": "*"

to the require section of your composer.json file.


Use Gridster.js as any other other Yii2 widget.

use fedemotta\gridster\Gridster;
$gridster = Gridster::begin([
        'widget_margins'=> [10, 10],
        'widget_base_dimensions'=> [140, 140],
        'autogrow_cols'=> false,

<?= $gridster->beginWidget([
        'data-row'=>"1", 'data-col'=>"1", 'data-sizex'=>"5", 'data-sizey'=>"2",
    <header>Some text</header>
    The widget content

        'data-row'=>"1", 'data-col'=>"1", 'data-sizex'=>"4", 'data-sizey'=>"1",
    <header>Some other text</header>
    The other widget content


You can also use Gridster.js in the JavaScript layer of your application. To achieve this, you need to include Gridster as a dependency of your Asset file.

public $depends = [