nachonavarro / Pages

📖 A lightweight, paging view solution for SwiftUI
MIT License
586 stars 55 forks source link

View Disappearing when Pages used multiple times #22

Open ehardacre opened 3 years ago

ehardacre commented 3 years ago

I have a menu that changes the content shown on the screen. In two of the different views I used Pages. Showing the first instance of Pages works fine, but when I go to the other view with an instance of Pages, the Pages view flashes and then disappears. Then if I try to go back the other one disappears as well. If I remove one instance of Pages it works fine.

ehardacre commented 3 years ago

I did a work around for this by copying the entire Pages project folder and pasting it into my project and renaming all the structs and classes (and then using the renamed version for one of my Pages instances). The issue is with the static functions in the function builder. I don't really know enough about function builders to mess around with that, so I did a lazy work around.