---
title: "Comment by Yuriy Novikov on \"Desktop app development with flutter\" | Hashnode"
description: "Thanx for the article. You use Visibility to show an appropriate view. Is it to eliminate if...else? Any drawbacks of such a technique? Are hidden widget trees"
url: "https://hashnode.com/posts/desktop-app-development-with-flutter/66a9ce721ed5652e69040825/comment/66abbe77ae48f4e330f7e541"
---

[Discussion](https://hashnode.com/posts/desktop-app-development-with-flutter/66a9ce721ed5652e69040825)

Comment [Desktop app development with flutter](https://hashnode.com/posts/desktop-app-development-with-flutter/66a9ce721ed5652e69040825)

[Yuriy Novikov](https://hashnode.com/@bigbott)

[Aug 1, 2024](https://hashnode.com/posts/desktop-app-development-with-flutter/66a9ce721ed5652e69040825/comment/66abbe77ae48f4e330f7e541)

Thanx for the article. You use Visibility to show an appropriate view. Is it to eliminate if...else? Any drawbacks of such a technique? Are hidden widget trees still there... or not?

[Alex Sinelnikov](https://hashnode.com/@avdept)

[Aug 1, 2024](https://hashnode.com/posts/desktop-app-development-with-flutter/66a9ce721ed5652e69040825/comment/66abbe77ae48f4e330f7e541#reply-66abc0c0019c6411c22e1d5e)

Yes, visibility widgets, even when hidden - stays in widget tree, but you can set replacement widget, by default its SizedBox.shrink().

In my case I didn't want if/else in that part of code and used Visibility()
