Remove all associated data values on element removal

Fixes #381. Clean up data that was previously set using `.data()` from the element and its children when it is removed from the DOM using `.remove()` or `.empty()`, but keep the data when the element is only detached from the DOM. Corresponds to jQuery behaviour.