Can someone explain better than Codeacademy the reason why the separate 'on' event handler is necessary to remove the html objects in question?
On 5.14, codeacademy says, re: removing html elements under the 'ready' code:
"The problem is that it won't work—jQuery looks for all the .items when the DOM is loaded, so by the time your document is ready, it's already decided there are no .items to .remove(), and your code won't work."
This makes no sense to me, as earlier in this same chapter (5.5), we removed html elements that were only added using jquery. Therefore they didn't exist when the page was loaded, yet we still were able to remove them.
I'd like to have a handle on the theory behind the 'on' event handler, so if someone could explain to me just what is going on, I'd really appreciate it.