const container = (name, customisation = null) => { if (typeof(name) !== "string") { throw new TypeError("Name of the container must be string."); } if (customisation !== null && typeof(customisation) !== "function") { throw new TypeError("Customisation must be null or function."); } const target = document.createElement("div"); target.classList.add("container"); target.id = "container-" + name; if (customisation) { customisation(target); } return target; }; export { container };