diff --git a/src/js/utils/dom.js b/src/js/utils/dom.js index 2aa0345..27d775c 100644 --- a/src/js/utils/dom.js +++ b/src/js/utils/dom.js @@ -18,7 +18,9 @@ export default class DOM { */ static createNode(tag, id = '', text = '') { const node = document.createElement(tag); - node.id = id; + if (id) { + node.id = id; + } if (text) { node.textContent = text;