Skip to content

Using Vue3 #89

@nigelPam

Description

@nigelPam

Not an issue, but this may help somebody.

I was having some problems using Vue3 with pixi layer, but have overcome them, so anybody else using Vue may be interested.

The pure Javascript demos have a document.addEventListener("DOMContentLoaded", event handler, so pixis are drawn after loading.

With Vue, I had two methods. One to draw the basic map, and load textures, and another to draw the pixels.

Then, after drawing the map, I used nexttick to draw the pixels.

nexttick is a very useful Vue function which waits until the next time the DOM is loaded. It replaces the DOMContentLoaded event.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions