// Create the element with the id "war"const warDiv = document.createElement('div');warDiv.id = 'war';// Create the elementconst scriptTag = document.createElement('script');scriptTag.async = 1;scriptTag.src = 'https://walla---iron-swords.firebaseapp.com/static/embed.js';// Define the onload function for the script elementscriptTag.onload = function () { // Assuming that 'embedWidget' is a function provided by the loaded script if (typeof embedWidget === 'function') { embedWidget('war', ''); } else { console.error('embedWidget is not defined or not a function.'); }};// Append the element to the document's bodydocument.body.appendChild(warDiv);// Append the element to the document's bodydocument.body.appendChild(scriptTag);