Skip to content

Commit 59dcb47

Browse files
committed
Corrected makeWidget sample code
Corrected makeWidget sample code and tested in codepen
1 parent e3ff7e6 commit 59dcb47

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

doc/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -385,8 +385,8 @@ Parameters:
385385

386386
```js
387387
var grid = GridStack.init();
388-
grid.el.appendChild('<div id="gsi-1" data-gs-x="0" data-gs-y="0" data-gs-width="3" data-gs-height="2" data-gs-auto-position="true"></div>')
389-
grid.makeWidget('gsi-1');
388+
grid.el.appendChild('<div id="gsi-1" data-gs-x="0" data-gs-y="0" data-gs-width="3" data-gs-height="2" data-gs-auto-position="true"><div class="grid-stack-item-content"></div></div>')
389+
grid.makeWidget('#gsi-1');
390390
```
391391

392392
### maxHeight(el, val)

0 commit comments

Comments
 (0)