steamclock / netable

A Swift library for encapsulating network APIs using Codable in a type-oriented way.
MIT License
99 stars 3 forks source link

Replace current example project with a more modern SwiftUI-friendly example #86

Closed brendanlensink closed 1 year ago

brendanlensink commented 3 years ago

High Level Goals

The example project should be as small and as simple as possible, while still providing examples for all the features of Netable listed below.

What the app actually does isn't super important, but usually some kind of Calendar/TODO/blog app makes the most sense as it's familiar to most people.

The goal is that a new user should be able to read briefly about a feature in the README, and then if they need extra guidance be able to refer to the example project for a more detailed implementation of the feature.

Examples to Include

There's a good chance I missed some stuff here, but this definitely seems like a good start. Also note not every example needs to be separate, as long as it's clear what's being demo'd each time.

Creating Netable Instances

Requests

Handling Errors

Stretch goals: Since netable is now an actor and immutable, we'll want to show how you do something simple like logging in without auth, then providing an auth token for all subsequent requests

brendanlensink commented 2 years ago

@Amy it's up to you if you want to modify the existing project, or start from a clean slate for this. Either way you'll want to branch off of https://github.com/steamclock/netable/pull/99 to get started if it isn't merged into main yet.

amyoulton commented 1 year ago

@brendanlensink #99 is merged so am I just branching off of main now?

brendanlensink commented 1 year ago

That's correct 🚀

amyoulton commented 1 year ago

@brendanlensink just setting up some basic project settings for the example. Are we wanting to include live previews? I turned them off because that seems to be our standard, but not sure if we feel that's a useful thing to include in the app.

amyoulton commented 1 year ago

This is completed and merged via #105!