Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fixes #2155.
Added Notes and See Also for `Elements.empty` to use `Element.destroy`
when appropriate.
  • Loading branch information
ibolmo committed Dec 20, 2011
1 parent 1959959 commit 23143c6
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions Docs/Element/Element.md
Expand Up @@ -1905,6 +1905,17 @@ Removes every item from the [Elements][] array, and the empty array.


* (*array*) This empty [Elements][] array. * (*array*) This empty [Elements][] array.


### Note:

`Elements.empty` does not destroy the elements inside. As best practice, always destroy your elements if they're no longer in use. For example:

$$('div').destroy().empty();

### See Also

- [Element:destroy][]




Elements Method: filter {#Elements:filter} Elements Method: filter {#Elements:filter}
------------------------------------------ ------------------------------------------
Expand Down Expand Up @@ -2053,6 +2064,7 @@ This method has been deprecated. Use [Elements:append][] instead.
[Element:inject]: #Element:inject [Element:inject]: #Element:inject
[Element:set]: #Element:set [Element:set]: #Element:set
[Element:get]: #Element:get [Element:get]: #Element:get
[Element:destroy]: #Element:destroy
[Element:grab]: #Element:grab [Element:grab]: #Element:grab
[Element:erase]: #Element:erase [Element:erase]: #Element:erase
[Element:setProperty]: #Element:setProperty [Element:setProperty]: #Element:setProperty
Expand Down

0 comments on commit 23143c6

Please sign in to comment.