Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 0d3a55a

Browse files
authored
Merge pull request gridstack#1302 from adumesny/develop
gridstack#1301 spelled out usage doc include
2 parents e7a57bb + 772387e commit 0d3a55a

File tree

2 files changed

+16
-6
lines changed

2 files changed

+16
-6
lines changed

README.md

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -64,21 +64,21 @@ Usage
6464
[![NPM version](https://img.shields.io/npm/v/gridstack.svg)](https://www.npmjs.com/package/gridstack)
6565

6666
```bash
67-
yarn install gridstack
67+
yarn add gridstack
6868
or
6969
npm install --save gridstack
7070
```
7171

7272
## Include
7373

74-
* local:
74+
* after you install:
7575

7676
```html
77-
<link rel="stylesheet" href="gridstack.min.css" />
78-
<script src="gridstack.all.js"></script>
77+
<link rel="stylesheet" href="node_modules/gridstack/dist/gridstack.min.css" />
78+
<script src="node_modules/gridstack/dist/gridstack.all.js"></script>
7979
```
8080

81-
* Using CDN (minimized):
81+
* or using CDN (minimized):
8282

8383
```html
8484
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/gridstack.min.css" />
@@ -92,6 +92,11 @@ if you need to debug, look at the git demo/ examples for non min includes.
9292
creating items dynamically...
9393

9494
```html
95+
<style type="text/css">
96+
.grid-stack { background: #FAFAD2; }
97+
.grid-stack-item-content { background-color: #18bc9c; }
98+
</style>
99+
95100
<div class="grid-stack"></div>
96101

97102
<script type="text/javascript">
@@ -103,6 +108,11 @@ creating items dynamically...
103108
... or DOM created items
104109

105110
```html
111+
<style type="text/css">
112+
.grid-stack { background: #FAFAD2; }
113+
.grid-stack-item-content { background-color: #18bc9c; }
114+
</style>
115+
106116
<div class="grid-stack">
107117
<div class="grid-stack-item">
108118
<div class="grid-stack-item-content">Item 1</div>

demo/demo.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ h1 {
2424
}
2525

2626
.grid-stack {
27-
background: lightgoldenrodyellow;
27+
background: #FAFAD2;
2828
}
2929

3030
.grid-stack-item-content {

0 commit comments

Comments
 (0)