Perspective Component Flashes On Page Startup When Display Prop Set To False

I have a perspective component with its display property bind to a boolean parameter and set to false by default.

image

When I use the component within a EmbeddedView with the parameter set to false as below:
image

The component still renders when I open the page, and there is a noticeable delay before it disappear. I am wondering if there is a solution for this?

Thanks in advance.

Right click the property and change the 'persistent' flag. Then the default state of the component will be persisted as false in the view config. By default, properties with bindings become non-persistent, to avoid serializing massive pieces of data into your view configuration - but sometimes you do want to store the initial state.

1 Like

The state of the display property depends on the input parameter. By setting it as persistent, the component always not render, and there is a noticeable delay before it appears when I set the parameter in EmbeddedView to True

:person_shrugging:

You have to decide on a state that works best for you. There's no free lunch. Bindings take some time to evaluate - there's always a round trip to the gateway and back, even if the calculation is ~instant.

I wouldn't call setting a conditional rendering a free lunch as this is achievable in most other platforms. But thanks for your clarification.

1 Like

Most other SCADA platforms?

1 Like

I almost always set persistent values to false, as this seems more appealing to me. I also mask loading by using CSS, whether it's a fade-in or zoom/ease-in. For example, I have my faceplates zoom in, this animation is around 1/2 second and when it's done everything is loaded. If you are seeing load times more than that, I would reevaluate what you are doing.

Thanks for the advice. I am considering using CSS to mask the loading too. Otherwise, I could also use a load screen to delay the page before it fully renders.