html head body要素を取得する
const scriptElement = document.createElement("script");
scriptElement.src = "./main.js"
document.head.appendChild(scriptElement);document.documentElement html要素
document.head head要素
document.body body要素
createElement ノードを作成する 要素を作成する
親ノード.insertBefore(子ノード, 直前のノード)
親ノード.appendChild(子ノード)