Do some refactoring and add private method _renderContentCallback for content rendering