Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/flozz/pavage
Lightweight library to arrange HTML elements in a Waterfall / Pinterest-like column layout
https://github.com/flozz/pavage
Last synced: 21 days ago
JSON representation
Lightweight library to arrange HTML elements in a Waterfall / Pinterest-like column layout
- Host: GitHub
- URL: https://github.com/flozz/pavage
- Owner: flozz
- License: mit
- Created: 2016-03-03T12:37:00.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2016-05-16T11:12:53.000Z (over 8 years ago)
- Last Synced: 2024-10-04T16:25:52.326Z (about 1 month ago)
- Language: JavaScript
- Homepage:
- Size: 5.86 KB
- Stars: 12
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Pavage
> Lightweight library to arrange HTML elements in a Waterfall / Pinterest-like column layout
![Example](https://raw.githubusercontent.com/flozz/pavage/master/demo.png)
## Quick Start
To use `pavage`, you just have to make some HTML and then call the `pavage.fromDOM()` function:
```html
...pavage.fromDOM();
```
* the `pavage` class must be set on each element that will contain item to render with pavage
* the `data-column` attribute defines the number of column that will be displayed (default: 3)
* the `data-spacing` attribute defines the spacing between items (default: 0)