From cf138e596bf6c04bf360c8998399b7939e44b2d4 Mon Sep 17 00:00:00 2001 From: David DeSandro Date: Fri, 6 May 2011 23:57:10 -0400 Subject: [PATCH] docs : elaborate on option method. Fixes #48 --- _posts/docs/2010-12-04-methods.mdown | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/_posts/docs/2010-12-04-methods.mdown b/_posts/docs/2010-12-04-methods.mdown index 62d6d38..c9048a5 100644 --- a/_posts/docs/2010-12-04-methods.mdown +++ b/_posts/docs/2010-12-04-methods.mdown @@ -91,7 +91,22 @@ Positions specified item elements in layout. {% endhighlight %} -Modifies options for plugin instance. +Modifies options for plugin instance. Can be used to get and set options. Unlike passing options through `.isotope()`, using the `option` method will not trigger layout. + +{% highlight javascript %} + +// sets multiple options +.isotope( 'option', { layoutMode: 'fitRows', filter: '.my-filter' } ) + +// set single option +.isotope( 'option', 'layoutMode', 'straightDown' ) + +// get option +.isotope( 'option', 'layoutMode' ) +// returns 'straightDown' + +{% endhighlight %} + ## reLayout