aboutsummaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorMark Otto <[email protected]>2012-03-25 17:37:38 -0700
committerMark Otto <[email protected]>2012-03-25 17:37:38 -0700
commit825227474b57c90181e9c1b43da952d01b6c1dc1 (patch)
treedd47a25f6c0715034f86d607695ca9d2c99ad058 /docs
parent3e2e111b17ff875a84773e00bd0b34ff8bf6bc3a (diff)
downloadbootstrap-825227474b57c90181e9c1b43da952d01b6c1dc1.tar.xz
bootstrap-825227474b57c90181e9c1b43da952d01b6c1dc1.zip
add refresh method documentation to js docs to close #2028 and #2795
Diffstat (limited to 'docs')
-rw-r--r--docs/assets/bootstrap.zipbin56863 -> 56863 bytes
-rw-r--r--docs/javascript.html8
-rw-r--r--docs/templates/pages/javascript.mustache8
3 files changed, 16 insertions, 0 deletions
diff --git a/docs/assets/bootstrap.zip b/docs/assets/bootstrap.zip
index f1239927e..e2911bc66 100644
--- a/docs/assets/bootstrap.zip
+++ b/docs/assets/bootstrap.zip
Binary files differ
diff --git a/docs/javascript.html b/docs/javascript.html
index 3cba210a1..70646afdb 100644
--- a/docs/javascript.html
+++ b/docs/javascript.html
@@ -571,6 +571,14 @@ $('#myModal').on('hidden', function () {
<strong>Heads up!</strong>
Navbar links must have resolvable id targets. For example, a <code>&lt;a href="#home"&gt;home&lt;/a&gt;</code> must correspond to something in the dom like <code>&lt;div id="home"&gt;&lt;/div&gt;</code>.
</div>
+ <h3>Methods</h3>
+ <h4>.scrollspy('refresh')</h4>
+ <p>When using scrollspy in conjunction with adding or removing of elements from the DOM, you'll need to call the refresh method like so:</p>
+<pre class="prettyprint linenums">
+$('[data-spy="scroll"]').each(function () {
+ var $spy = $(this).scrollspy('refresh')
+});
+</pre>
<h3>Options</h3>
<table class="table table-bordered table-striped">
<thead>
diff --git a/docs/templates/pages/javascript.mustache b/docs/templates/pages/javascript.mustache
index e037dd024..a5010f226 100644
--- a/docs/templates/pages/javascript.mustache
+++ b/docs/templates/pages/javascript.mustache
@@ -494,6 +494,14 @@ $('#myModal').on('hidden', function () {
<strong>{{_i}}Heads up!{{/i}}</strong>
{{_i}}Navbar links must have resolvable id targets. For example, a <code>&lt;a href="#home"&gt;home&lt;/a&gt;</code> must correspond to something in the dom like <code>&lt;div id="home"&gt;&lt;/div&gt;</code>.{{/i}}
</div>
+ <h3>{{_i}}Methods{{/i}}</h3>
+ <h4>.scrollspy('refresh')</h4>
+ <p>{{_i}}When using scrollspy in conjunction with adding or removing of elements from the DOM, you'll need to call the refresh method like so:{{/i}}</p>
+<pre class="prettyprint linenums">
+$('[data-spy="scroll"]').each(function () {
+ var $spy = $(this).scrollspy('refresh')
+});
+</pre>
<h3>{{_i}}Options{{/i}}</h3>
<table class="table table-bordered table-striped">
<thead>