Add [AllowDynamicProperties] in the base view class for J5. Move the _prepareDocument above the display call in the base view class.