Commit b39d6ff0 authored by TasteBot's avatar TasteBot

update the build files for gh-pages [ci skip]

parent eb0bf678
......@@ -107,8 +107,11 @@ func (v *App) CreateTodo(ev dom.Event) {
if !ok {
panic("Could not convert event target to dom.HTMLInputElement")
}
v.Todos.AddTodo(strings.TrimSpace(input.Value))
document.QuerySelector(".new-todo").(dom.HTMLElement).Focus()
title := strings.TrimSpace(input.Value)
if title != "" {
v.Todos.AddTodo(title)
document.QuerySelector(".new-todo").(dom.HTMLElement).Focus()
}
}
// ClearCompleted is an event listener which removes all the completed todos
......
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment