1
0
Fork 0
mirror of https://github.com/twbs/bootstrap.git synced 2022-11-09 12:25:43 -05:00

add refresh method documentation to js docs to close #2028 and #2795

This commit is contained in:
Mark Otto 2012-03-25 17:37:38 -07:00
parent 3e2e111b17
commit 825227474b
3 changed files with 16 additions and 0 deletions

Binary file not shown.

View file

@ -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>

View file

@ -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>