<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>22711</bug_id>
          
          <creation_ts>2013-07-17 09:50:41 +0000</creation_ts>
          <short_desc>Add a .empty method to the ParentNode (or the Node?) interface</short_desc>
          <delta_ts>2014-02-12 20:10:12 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebAppsWG</product>
          <component>DOM</component>
          <version>unspecified</version>
          <rep_platform>PC</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>17426</dup_id>
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="David Bruant">bruant.d</reporter>
          <assigned_to name="Anne">annevk</assigned_to>
          <cc>mike</cc>
    
    <cc>mounir</cc>
    
    <cc>syoichi</cc>
    
    <cc>www-dom</cc>
          
          <qa_contact>public-webapps-bugzilla</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>90835</commentid>
    <comment_count>0</comment_count>
    <who name="David Bruant">bruant.d</who>
    <bug_when>2013-07-17 09:50:41 +0000</bug_when>
    <thetext>Pretty much the standard equivalent of http://api.jquery.com/empty/
Currently, one has to do something like:
  element.innerHTML = &apos;&apos;;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>90841</commentid>
    <comment_count>1</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2013-07-17 13:54:22 +0000</bug_when>
    <thetext>What&apos;s wrong with .textContent = &quot;&quot;? See also bug 17426 and http://krijnhoetmer.nl/irc-logs/whatwg/20120605#l-780</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>91353</commentid>
    <comment_count>2</comment_count>
    <who name="David Bruant">bruant.d</who>
    <bug_when>2013-07-28 11:06:27 +0000</bug_when>
    <thetext>(In reply to comment #1)
&gt; What&apos;s wrong with .textContent = &quot;&quot;?
As much as there is something wrong with node.parentNode.removeChild(node). It&apos;s doesn&apos;t say what it means.
Not everyone is expert enough in the DOM aware of the textContent=&quot;&quot; trick and some people just traverse all childNodes to remove them one by one.


&gt; See also bug 17426 and
&gt; http://krijnhoetmer.nl/irc-logs/whatwg/20120605#l-780
I&apos;m not sure I understand what I should be seeing there. People seem to agree, no? (I&apos;ll let others debate on the chaining aspect, I just want the .empty())</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>100434</commentid>
    <comment_count>3</comment_count>
    <who name="Anne">annevk</who>
    <bug_when>2014-02-12 20:10:12 +0000</bug_when>
    <thetext>

*** This bug has been marked as a duplicate of bug 17426 ***</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>