Skip to content

Commit

Permalink
Fix viewRenderer on size changed (Flipkart#762)
Browse files Browse the repository at this point in the history
  • Loading branch information
shiroyk committed Sep 2, 2023
1 parent afd0a8b commit 54a6264
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/platform/web/viewrenderer/ViewRenderer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ export default class ViewRenderer extends BaseViewRenderer<any> {
private _checkSizeChange(fromObserver: boolean = false): void {
if (this.props.forceNonDeterministicRendering && this.props.onSizeChanged) {
const mainDiv = this._mainDiv;
if (mainDiv) {
if (mainDiv && mainDiv.clientWidth && mainDiv.clientHeight) {
this._dim.width = mainDiv.clientWidth;
this._dim.height = mainDiv.clientHeight;
if (this.props.width !== this._dim.width || this.props.height !== this._dim.height) {
Expand Down

0 comments on commit 54a6264

Please sign in to comment.