Skip to content

Commit

Permalink
README: use modifiers array in example
Browse files Browse the repository at this point in the history
  • Loading branch information
taye committed Jun 1, 2018
1 parent 01f2b84 commit 1404c17
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,13 @@ var pixelSize = 16;
interact('.rainbow-pixel-canvas')
.origin('self')
.draggable({
snap: {
targets: [ interact.createSnapGrid({
modifiers: [
interact.modifiers.snap({
targets: [ interact.snappers.grid({
x: pixelSize, y: pixelSize
}) ]
},
}) ],
}),
],
// allow multiple drags on the same element
maxPerElement: Infinity
})
Expand Down

0 comments on commit 1404c17

Please sign in to comment.