Permalink
Browse files

correct judge.store.validate doc

  • Loading branch information...
1 parent 207171a commit 834fcd7a7851087f176391239ede6525cf9b4138 @joecorcoran committed Apr 1, 2012
Showing with 5 additions and 3 deletions.
  1. +5 −3 index.html
View
@@ -263,7 +263,7 @@ <h5>save <code>judge.store.save(key, element)</code></h5>
<pre class="sh_javascript">judge.store.save('mykey', document.getElementById('foo'));
// => [ { element:HTMLInputElement, &hellip; } ]
-judge.store.save('mykey', document.getElementByTagName('input'));
+judge.store.save('mykey', document.getElementsByTagName('input'));
// => [ { element:HTMLInputElement, &hellip; }, { element:HTMLInputElement, &hellip; }, &hellip; ]</pre>
<h5>get <code>judge.store.get(key)</code></h5>
<p>Return an array of watchers saved against the key. If no key is given, the store object is returned.</p>
@@ -295,8 +295,10 @@ <h5>remove <code>judge.store.remove(key, element)</code></h5>
// => { mykey:[ &hellip; ], mykey2:[ &hellip; ] }</pre>
<h5 id="clear">clear <code>judge.store.clear(key)</code></h5>
<p>Remove all watchers stored against a key or, if no key is given, all stored watchers. Returns store object after watchers were removed.</p>
- <pre class="sh_javascript">judge.store.clear('mykey');
- // => { mykey:[], &hellip; }
+ <pre class="sh_javascript">judge.store.save('inputs', document.getElementsByTagName('input'));
+judge.store.save('textareas', document.getElementsByTagName('textarea'));
+judge.store.clear('inputs');
+ // => { textareas: [ HTMLInputElement &hellip; ] }
judge.store.clear();
// => {} </pre>
</div>

0 comments on commit 834fcd7

Please sign in to comment.