Read the transcript
Jeroen Leenarts: Hi, and welcome
to the 44th episode of my
podcast. My name is Jeroen
Leenarts. And I've been
developing software for over 80
years, developing iOS apps for
over nine years and running
logical catch for close to eight
years. If you are an iOS app
developer, you should listen to
my podcast because we'll keep
you updated on interesting
articles and events you might
not have heard about. In this
episode, I'm going to talk about
a pretty swift UI environment
failure explains how to define
custom environment failures in
Swift UI. Why conditional view
modifiers are a bad idea. Using
foul wrappers in Swift UI app,
find a problematic few in the
few debugger. And Don is Monday
morning tweet. So let's get
started. One thing that you will
notice in my episode this week,
is that there's a lot of Swift
UI related content in there. And
that's due to the fact that I'm
working a lot more with Swift UI
in my day job. So that's a lot
of hours spent developing swift
UI code, getting to know the
framework more intimately. And
also wanting to look up more
resource and learn about how you
can use Swift UI properly. So
this automatically, in my case,
makes the articles on stretch,
why stick out more on my feet.
And that's also why I chose to
have have very happy swift UI
focused episodes this time
around. I hope you like it, too.
And actually, I hope you can use
Swift UI in your day job or in
your project as much as I can do
right now. Because it's really
enjoyable. And it's, it's
something different than what
I've been doing for the last few
years with UI kits and related
technologies. Also, with my
keyboard journey, I'm still
trying to discover what I really
like I'm switching my switches,
and I'm really trying different
things every now and then. And
yeah, I must say that on this
Atrius keyboard, I'm getting the
hang of it, and my words per
minute is starting to rise
again. So really enjoying that
as well. On another note, my
daughter is finally back to
school after the summer
holidays. And she was really
looking forward to that. And
this afternoon, she came home
from school. And she was really
happy it was it was such joy to
see how much he enjoyed her day
today. So I'm looking forward to
a new year for her own school.
And if this first day is any
indication how the rest of the
year could be, then then I'm all
for it. So let's dive in. Every
stretch why environment fell
explained. streetwise
environment is one of the most
important pillars of Apple's
declarative UI framework. There
are many aspects of this
infrastructure. In his article,
Federico refuse all environment
fails that swift UI offers. It's
a long article, and there's a
lot of stuff in there. But I
think it's one of those
articles. That's a very
convenient overview with some
more sample code on how you can
actually use all these 50 Wind
Farm values. So I think this is
one that you will come back to
every now and then when you're
dealing with this switch to our
environment values, and that you
want to have a little bit
explanation on them. So once you
get familiar with Swift wise
environment values, you'll
probably want to define your
own. And saloon has just the
article on that how to define
custom environment files is 50.
Why saloon has done a previous
article on how you can use the
environment to pass value such
as your locale and calendar to
review archy. It is linked from
this article. So we all know
that the environment is somewhat
of a key value store. But what
if it would be possible to
create your own custom key
values? And that you can
actually use those in your Swift
UI app as well. Insurance
article, you get to know how
over at objective c.io
They recently published a new
article, Chris, I'd have
actually wrote this one. They
don't published very often, but
once they do, it's, it's usually
a very good article. So the
article is titled Why
conditional few modifiers are a
bad idea. In the Swift UI
community, many people come up
with their own version of a
conditional few modifier. It
loves to take few and only apply
a few modifier when the
condition holds. What Chris has
noticed is that in a lot of the
sample code that he sees online
about these types of conditional
fuel modifiers there are some
problems in there. So in his
article, Chris actually explores
what his problems are, and
explains to you why you should
be very careful when considering
a conditional view modifier. So
tread carefully when you're
using conditional view modifiers
and read Chris's article. To
learn a lot more on details.
Mark wrote an article on using
File wrappers in the script UI
app. A file wrapper is a bundle,
which is a collection of one or
more directories, folders and
files that appeared as a single
file. And finally, we all know
these, because for instance,
every app that you start on Mac
OS is actually a file wrapper.
If you want to see what these
file wrappers look like what
these bundles look like, select
an application in your finder,
right click it and choose Show
Package Contents. So why should
you use a file wrapper? You use
a file wrapper when you want to
save your App State multiple
files. Suppose you're developing
a website. A website can have
multiple pages plus folders and
files for images, videos, and
custom CSS. By using a file
wrapper, you can save all these
files, and have it look like a
single file to the person using
your app. Most apps don't need
to use File wrappers. But still,
it's a very convenient thing to
know about. And there are some
special use cases that you
really want to use this feature.
So in this article, Mark
explains how you can make your
own file wrapper appear as a
single file, and I can create a
document file wrapper. So
there's a lot of code in this
article that allows you to get
familiar with all the details of
creating and using File wrappers
in your own code. He also has a
sample project available on
GitHub that you can use to see
how this looks in practice. The
last article I wanted to mention
is by Dominic Houser, it's a
very convenient debugging thing,
it's something you need to just
know about. And once you're
familiar with it, you cannot
imagine how he ever got by
without it. His article is
called Find a programmatic few
interview debugger. If you have
a layered constraint issue
that's being printed in your
console, you could read that
information and try to figure
out what the problematic view is
at that point in time. But
there's actually an easier way,
in the last line, Xcode tells
you which constraint it chose to
break. So when you see this
message, you should copy the ID
from this view. And with this
address, you can actually look
things up in the view debugger
in Xcode. So Dominic explains
everything with samples and
example prints, and how it
actually looks on screen in
Xcode. But just knowing this one
trick, it really allows you to
visualize what these constraints
are that are being broken when
you see this lock message. So
those are the articles for this
week. Let's move on to Danny's
Monday morning sweet. I always
enjoyed this one. Stuart Lynch
has been busy, he has been
producing 10 videos to
completion. And they are all
scheduled for release for an
update to my his To Do app
series using iOS 15 and drawing
functions. Once 50 Why
fundamentals and five in the new
series on imaging camera picker
with zoom image view in Swift
UI. Definitely check this guy
out. Stuart has been on my
podcast and he's a great video
creator on YouTube. Ricardo is
refactoring and detangling. A
bunch of codes combined is
involved. And the book by Donnie
is very helpful. Leo GD on is
building a Swift package from
MailChimp and refactoring the
network code. So it will work
with iOS Swift, Neo and favor.
He's also getting ready for an
interview with Ariel Medallia on
ASL and learning about migrating
from Xcode projects to Swift
package manager, a bunch of iOS
15 And watch OS eight bug fixes.
Vincent is doing a new challenge
this week and he's starting to
post his content on tick tock,
very curious how this all worked
out. And Dennis says good
morning. And it's the last week
before he's going to have on a
break and change jobs to the
Dutch Railways as an iOS deaf
for the rice planner. He is also
working on a little Pomodoro app
for the Apple Watch. And Jerome
is getting started in his
biggest side project effort
opening a Twitch channel where
once a week he will live called
an iOS Mac OS from scratch to
the App Store. Limited DFS is
saying Happy Monday he's working
on a watch West app for the
bluebird app, and also combating
some self doubt with his new
piece of comic. And it's a very
fun comic about what any
lifestyle looks like how it is
in practice and how you feel
about it afterwards.
And Miguel is saying Happy
Monday I've been teaching myself
how to integrate share action
extensions to perform a task
before launching his app. And
Danya Sadie is trying to wrap up
a new stretch y three app that
he's hoping to release when iOS
15 goes live co spending some
time with his family and he is
apparently in some cornfields
and picking some beans on the
farm. Adam is learning core
audio. And Dominic is currently
almost at the end of Shawn Allen
that take home project course.
So all in all, a lot of stuff is
happening. It's it's extremely
busy what people have been
doing, like compared to last
week. And it's really nice to
see how everybody is really
picking up the pace again and
getting ready for releasing new
products as the IFRS 15 release
gets closer and close. And
that's it for this week. I hope
you enjoyed my podcast. Listen
to me again next week. Most of
all, read me on Apple podcasts
or any other platform that
you're capable of reviewing. And
just let me know what you think
about my podcast sent me a DM on
Twitter at app Force One. Talk
to you again next week.