3 ms·
> Don't count on the "live preview" though. That thing never works for anything other than the most trivial of examples. this was the one thing i would have ho
by andrekandre 6y ago
> Don't count on the "live preview" though. That thing never works for anything other than the most trivial of examples.
this was the one thing i would have hoped they would have finally fixed... wether its with xib/storyboards or swiftui, not getting realtime feedback on layouts is infuriating...
- read_if_gay_ 6y agoIt works for me for a few not-quite-trivial views (e.g. a plot). It got a lot better with Xcode 12. The main thing now is if it doesn't work the error messages are basically useless, so you have to be very careful in setting it up. At least for me, the error message often made it seem like a random issue with Live Preview but it actually boiled down to some mistake in my code.
- andrekandre 6y ago> boiled down to some mistake in my code. yes, this is the hard part i think, and it was a similar issue with even storyboards/xib... since everything is in the same module, an issue somewhere else prevents compilation and hence the preview dies* * maybe that is a reason until recently, declarative xml layout was used for a long time, no need to worry about compilation failure to get previews (in theory anyways)