update the dom element after updating the subject.