3 ms·
As a way of interacting with the DOM, this makes me very uncomfortable: # add the task element to the page as new node in the list by cloning taskHtml
by mft_ 4y ago
As a way of interacting with the DOM, this makes me very uncomfortable:
# add the task element to the page as new node in the list by cloning
taskHtml = task_template.clone(task_id, to=task_list)
taskHtmlContent = taskHtml.select('p')
taskHtmlContent.element.innerText = task['content']
taskHtmlCheck = taskHtml.select('input')
task_list.element.appendChild(taskHtml.element)
We can surely make such things easier in 2022?
- saghm 4y agoI imagine that if Python were supported out of the box in browsers like JavaScript is, frameworks would emerge for this sort of thing. At this point though, I'm not sure I think it's particularly likely that browsers will support additional languages instead of just preferring people compile to WASM and use some JavaScript over it.