Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
rucksack.js arranges your elements into a proper beautiful arrangement in a given width constraint.
JavaScript
tree: cb5e6f775e

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
README.md
rucksack.js

README.md

Rucksack

Rucksack is a jquery plugin to arrange elements that can fit in the given width. It relies on the knapsack algorithm.

Usage:

$('#container').rucksack({
    width: 'width to fit in. defaults to 960px',
    class: 'class name to be given to the div that will contain the elements of one row. defaults to rucksack'
})

Example

Here's a working example by @omgmog

http://jsfiddle.net/vXbCY/

Another example by ctcherry

http://jsfiddle.net/URMuA/

Contributors:

1) gauravsc

Something went wrong with that request. Please try again.