1
0
mirror of https://github.com/morris/vanilla-todo.git synced 2025-08-21 13:21:29 +02:00
This commit is contained in:
Morris Brodersen
2020-10-27 17:03:45 +01:00
parent 9cd1868e96
commit 9295fafd61

View File

@@ -46,14 +46,14 @@ VT.TodoItemInput = function (el) {
if (label === '') return; if (label === '') return;
inputEl.value = '';
el.dispatchEvent( el.dispatchEvent(
new CustomEvent('addItem', { new CustomEvent('addItem', {
detail: { label: inputEl.value }, detail: { label: label },
bubbles: true, bubbles: true,
}) })
); );
inputEl.value = '';
} }
function clear() { function clear() {