Skip to content
This repository was archived by the owner on Mar 18, 2025. It is now read-only.
This repository was archived by the owner on Mar 18, 2025. It is now read-only.

Flickering when adding an element into the DOM #36

Closed

Description

@shirakaba

Reported on the Svelte Discord, on the #nativedev channel by user _nothing, who had just been experimenting with svelte-nodegui-starter:

Screen_Recording_2021-03-05_at_5.29.31_PM.mov

I tried out svelte-nodegui and got it running! Any tips on how to avoid this weirdness? I'm assuming it takes a moment for the styles to be applied to the other component, but it's just slow enough that it's very obvious.

The second component is rendered conditionally via:

{#if showSecond}
  <StepTwo />
{/if}

It's happening when the elements are added, by the way. Not removed.

_nothing confirmed that setting a fixed window size didn't improve the situation.

Activity

  1. shirakaba commented on Mar 5, 2021

    @shirakaba
    CollaboratorAuthor

    It looks like, during the flicker, the button starts huge:

    0:02:

    image

    0:06:

    image

    It's interesting to note that, although it starts huge, it does start consistently the same size both times. Things would be clearer if we reduced the paddings and margins to understand whether it's growing to a certain container size or some other logical size.

    @a7ul does this look like familiar behaviour at all? Could it possibly be anything to do with yoga, or is it a known problem with Qt itself?

  2. a7ul commented on Mar 6, 2021

    @a7ul
    Contributor

    Hey this should be fixed in the latest version

    there was a pr for bugs with flex layout here: nodegui/nodegui#814

    can you bump the nodegui and react nodegui versions underneath?

  3. shirakaba commented on Mar 14, 2021

    @shirakaba
    CollaboratorAuthor

    Thanks @a7ul! Sorry for the late reply. This'll be my top priority next time I'm doing some open-source. Have just been taking a break since the initial release!

  4. self-assigned this
    on Mar 14, 2021
  5. shirakaba commented on Mar 20, 2021

    @shirakaba
    CollaboratorAuthor

    Fixed in v0.0.2-alpha.2!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions