aboutsummaryrefslogtreecommitdiff
path: root/files/fr/orphaned/web/api/parentnode/firstelementchild
diff options
context:
space:
mode:
authorMDN <actions@users.noreply.github.com>2021-04-16 00:10:51 +0000
committerMDN <actions@users.noreply.github.com>2021-04-16 00:10:51 +0000
commit9daad59fa2578dcc9603833b0a9a22b93d362b5e (patch)
treecf66aa37e5a7f19aff75a5e8d2b2773f0b295048 /files/fr/orphaned/web/api/parentnode/firstelementchild
parent91bea6bd04ae368a889436799187eeebb11d33a1 (diff)
downloadtranslated-content-9daad59fa2578dcc9603833b0a9a22b93d362b5e.tar.gz
translated-content-9daad59fa2578dcc9603833b0a9a22b93d362b5e.tar.bz2
translated-content-9daad59fa2578dcc9603833b0a9a22b93d362b5e.zip
[CRON] sync translated content
Diffstat (limited to 'files/fr/orphaned/web/api/parentnode/firstelementchild')
-rw-r--r--files/fr/orphaned/web/api/parentnode/firstelementchild/index.html46
1 files changed, 46 insertions, 0 deletions
diff --git a/files/fr/orphaned/web/api/parentnode/firstelementchild/index.html b/files/fr/orphaned/web/api/parentnode/firstelementchild/index.html
new file mode 100644
index 0000000000..ae70e6aa66
--- /dev/null
+++ b/files/fr/orphaned/web/api/parentnode/firstelementchild/index.html
@@ -0,0 +1,46 @@
+---
+title: Element.firstElementChild
+slug: orphaned/Web/API/ParentNode/firstElementChild
+tags:
+ - Parcours arborescence
+translation_of: Web/API/ParentNode/firstElementChild
+original_slug: Web/API/ParentNode/firstElementChild
+---
+<p>{{ gecko_minversion_header("1.9.1") }}</p>
+
+<p>{{ ApiRef() }}</p>
+
+<h3 id="Summary" name="Summary">Résumé</h3>
+
+<p><strong><span style="font-family: Verdana,Tahoma,sans-serif;">firstElementChild</span></strong> renvoie le premier élément enfant d'un élément ou <code>null</code> s'il n'y a pas de descendants.</p>
+
+<h3 id="Syntax_and_values" name="Syntax_and_values">Syntaxe and valeurs</h3>
+
+<pre class="eval">var <em>N</em><em>oeudEnfant</em> = ReferenceElementNoeud.firstElementChild; </pre>
+
+<p><var>NoeudEnfant</var> est une référence vers le premier élément enfant de l'élément noeud , ou <code>null</code> s'il n'y en a pas.</p>
+
+<p>Cet attribut est en lecture seule.</p>
+
+<h3 id="Example" name="Example">Exemple</h3>
+
+<pre>&lt;p id="para-01"&gt;
+ &lt;span&gt;Premier span&lt;/span&gt;
+&lt;/p&gt;
+
+&lt;script type="text/javascript"&gt;
+ var p01 = document.getElementById('para-01');
+ alert(p01.firstElementChild.nodeName)
+&lt;/script&gt;</pre>
+
+<p>Dans cet exemple la fonction alert affiche "SPAN", qui est le nom du premier nœud enfant de l'élément paragraphe.</p>
+
+<h3 id="Voir_aussi">Voir aussi</h3>
+
+<ul>
+ <li><a class="internal" href="/en/DOM/Element.childElementCount" title="En/DOM/Element.childElementCount"><code>childElementCount</code></a></li>
+ <li><a class="internal" href="/en/DOM/Element.children" title="En/DOM/Element.children"><code>children</code></a></li>
+ <li><a class="internal" href="/en/DOM/Element.lastElementChild" title="En/DOM/Element.lastElementChild"><code>lastElementChild</code></a></li>
+ <li><a class="internal" href="/en/DOM/Element.nextElementSibling" title="En/DOM/Element.nextElementSibling"><code>nextElementSibling</code></a></li>
+ <li><a class="internal" href="/en/DOM/Element.previousElementSibling" title="En/DOM/Element.previousElementSibling"><code>previousElementSibling</code></a></li>
+</ul>