I spent most of today reworking the core logic of @TheMugshotBot and really enjoyed it! This is super exciting because it opens up a lot of new opportunities for upcoming themes and customizations. And ironed out a bunch of bugs.
A big help was commenting out the entire model and TDDing the bulk of the logic. I missed a few things on the first pass, but was able to backfill a feature or two and then wrap it in tests.

I'm all for this "TDDish" approach I've developed over the past few years!
Deep in the weeds...

The code had a bunch of features slapped on here and there. Taking the time document the entire flow (on paper!) and then reimplementing helped consolidate a lot of logic and missed edge cases.

All the more reason to dedicate time to refactoring!
I'm planning on adding some smarter page caching this week before I launch, so don't expect any changes live on the site just yet. But let me know if you'd like to help beta test!

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Joe Masilotti

Joe Masilotti Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @joemasilotti

2 Feb
XCTest tips and tricks that can level up your Swift testing.

🧵👇
1. Use XCTUnwrap instead of force wrapping optionals

Force unwrapping a nil will cause the test suite to completely crash, meaning no output or reporting. XCTUnwrap provides a nice failure message and fails the test.
2. Set continueAfterFailure to false

If you have multiple assertions in a test they might increase in specificity. The first asserts the size of the array and the second assets the first element. You don't want to run the second if the first fails, it's just noise.
Read 12 tweets
19 Jan
I spent exactly 8.5 hours this weekend and built a fully functioning SwiftUI app. It uses open data to map the Heritage Trees of Portland, OR.

It's also open source. I'm planning on continuing to build this in public. github.com/joemasilotti/p…
My first pass was a simple list view showing each tree. This downloads data from an open API provided by the city of Portland.

I experimented with Combine and URLSession's dataTaskPublisher to get this working in MVVM fashion.
portlandmaps.com/metadata/index… Image
Next up was a bare-bones detail screen. I mapped some of the important properties in a new screen via NavigationLink. Image
Read 8 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!

Follow Us on Twitter!