It should not be capturings responsibility to remove height and width attributes. If this is needed, the user can freely do so using dom methods on capturedDoc.