Using the .task view modifier

The .onAppear view modifier allows you to execute costly initialization only when a view becomes visible. The .task view modifier allows breaking out asynchronous initialization.

Interacting with Endpoints (Updated)

If your application talks to a server to get data, you're going to need to interface with server endpoints. Here is an introduction to one way to interact with endpoints. Now updated with source code and an example!