<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>lazy_skunk</author_name>
  <author_url>https://blog.hatena.ne.jp/lazy_skunk/</author_url>
  <blog_title>ちんぱんの雑記</blog_title>
  <blog_url>https://lazy-skunk.hatenablog.com/</blog_url>
  <categories>
  </categories>
  <description>DOM 操作で DocumentFragment を使うと性能が上がる！と断言したかったが、調べていくうちに「場合による」くらいに落ち着いた話。 DocumentFragment を使う例 複数の要素を一度フラグメントへ追加し、最後にまとめてリストへ移す例と、直接リストへ追加する例を並べてみた。 function createListWithFragment() { const fragment = document.createDocumentFragment(); const list = document.createElement(&quot;ul&quot;); for (let i = 0; i &lt; …</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Flazy-skunk.hatenablog.com%2Fentry%2F2024%2F10%2F15%2F231056&quot; title=&quot;DocumentFragment を使った DOM 操作の効率化 - ちんぱんの雑記&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2024-10-15 23:10:56</published>
  <title>DocumentFragment を使った DOM 操作の効率化</title>
  <type>rich</type>
  <url>https://lazy-skunk.hatenablog.com/entry/2024/10/15/231056</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
