Skip to content

Commit d8b7f99

Browse files
committed
Correct documentation of callback arguments
Both `$.fn.before` and `$.fn.after` invoke the supplied function with two arguments: the numeric index of each element in the set and the string markup describing each element's contents. The type of these arguments is correctly documented, but the description of the second argument is omitted. Include this information based on the documentation for similar behavior in `$.fn.append`.
1 parent 357f4d1 commit d8b7f99

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

entries/after.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
<signature>
2222
<added>1.4</added>
2323
<argument name="function" type="Function">
24-
<desc>A function that returns an HTML string, DOM element(s), or jQuery object to insert after each element in the set of matched elements. Receives the index position of the element in the set as an argument. Within the function, <code>this</code> refers to the current element in the set.</desc>
24+
<desc>A function that returns an HTML string, DOM element(s), or jQuery object to insert after each element in the set of matched elements. Receives the index position of the element in the set and the old HTML value of the element as arguments. Within the function, <code>this</code> refers to the current element in the set.</desc>
2525
<argument name="index" type="Integer" />
2626
<argument name="html" type="String" />
2727
<return>

entries/before.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
<type name="Element"/>
2929
<type name="jQuery"/>
3030
</return>
31-
<desc>A function that returns an HTML string, DOM element(s), or jQuery object to insert before each element in the set of matched elements. Receives the index position of the element in the set as an argument. Within the function, <code>this</code> refers to the current element in the set.
31+
<desc>A function that returns an HTML string, DOM element(s), or jQuery object to insert before each element in the set of matched elements. Receives the index position of the element in the set and the old HTML value of the element as arguments. Within the function, <code>this</code> refers to the current element in the set.
3232
</desc>
3333
</argument>
3434
</signature>

0 commit comments

Comments
 (0)