1
0
mirror of https://github.com/webslides/WebSlides.git synced 2025-08-29 16:00:31 +02:00

Fix createNode adding id when is empty

This commit is contained in:
Luis
2017-05-06 13:17:28 +02:00
parent d150b00014
commit f0a67fbc53

View File

@@ -18,7 +18,9 @@ export default class DOM {
*/ */
static createNode(tag, id = '', text = '') { static createNode(tag, id = '', text = '') {
const node = document.createElement(tag); const node = document.createElement(tag);
node.id = id; if (id) {
node.id = id;
}
if (text) { if (text) {
node.textContent = text; node.textContent = text;