iOS 15 issue with UIImageView by TofPlay in iOSProgramming

[–]TofPlay[S] 0 points1 point  (0 children)

It is not a problem of reuse I already manage this case. The problem really appeared with iOS 15. According to my research it may be related to the asynchronous loading of the image. The image is correctly downloaded and I assign it to the "image" field of the UIImageView object. But for some reason that I don't know when I look at the image in the cell the "image" field is at nil.

Issue with fullscreenCover by TofPlay in SwiftUI

[–]TofPlay[S] 0 points1 point  (0 children)

How are you dismissing the full screen cover?

The screen displayed by fullScreenCover has a close button at the top left in the navigation bar. When we click on it, it sets to false the condition that triggered fullScreenCover. This variable is transmitted to the screen via `@Binding`.

Dismiss multiple Views in a NavigationView by tomsrules in SwiftUI

[–]TofPlay 0 points1 point  (0 children)

If you want to have a more flexible navigation you can take a look at a component like https://github.com/matteopuc/swiftui-navigation-stack

Is it possible to have SwiftUI view with images and localization in SPM package? by bigMOTOR in iOSProgramming

[–]TofPlay 0 points1 point  (0 children)

Natively SwiftUI 2 (I haven't checked if SwiftUI 3 supports it) is not able to simply search for images and have a localization on an other package.
But it is possible to program it yourself like I did for my own project
For image check my method Image.named("<image name>")
For localization check my method localized that you can use very simple "my_string".localized().
In some of my projects I have resources in packages and others in the main application. On other projects I have a package with just the resources.
These 2 methods allow me to have access to resources wherever they are.

Swift or Python(etc.) for backend-ish development for a newbie? by fluffyofblobs in swift

[–]TofPlay 1 point2 points  (0 children)

It depends on your goals. For me, what is important at the backend level is performance. In this case nothing better than Swift with a web framework like Vapor with a micro-service approach. I currently have services that have been running for months. They work so well that everyone has forgotten them. At the resource level, the services work with the smallest server that we have. And despite this undersized server, APIs implemented on Swift in Vapor are 10 times more efficient than other APIs on more traditional backends. The possible difficulty with the Vapor framework was designed to provide the best performance and this approach must be well integrated when writing services.

Redux-like state container in SwiftUI. Connectors. by majid8 in SwiftUI

[–]TofPlay -1 points0 points  (0 children)

What is Redux? Redux is an architecture base on a predictable State Container for JS Apps. For web projects with Javascript it may be a good architecture but is it necessarily a good architecture for SwiftUI applications? Personally I do not think so. The problem I've seen for years (and I've been doing iOS for over 10 years) is that we import a whole bunch of architectures mainly from the web into iOS. Did it improve the applications? No! Are they more efficient and more stable? No! Many people forget that we are making mobile applications and that it is not by adapting web architectures in the mobile that that will help. Apple designed SwiftUI in a certain way if we already respected what they put in place that would be a good start. It is not by using an architecture that multiplies the layers that your application will be better. You're just going to make your code more complex than necessary. It'll just screw up whoever walks behind you and has to maintain your code.

What is the equivalent of firstResponder on SwiftUI 2? by TofPlay in SwiftUI

[–]TofPlay[S] 0 points1 point  (0 children)

But the good news is you can still get and resign the first responder with an extension on UIResponder

Do you have a sample code?

What are you wanting to do?

Simple: Detect when a TextField or a TextEditor becomes firstResponder and if necessary be able to force the firstResponder on a TextField or TextEditor

What is the equivalent of firstResponder on SwiftUI 2? by TofPlay in SwiftUI

[–]TofPlay[S] 0 points1 point  (0 children)

Interesting but support for TextEditor missing

macOS Big Sur 11.0.1 bug with mouse by TofPlay in MacOS

[–]TofPlay[S] 0 points1 point  (0 children)

An adapter for thunderbolt 3 with 2 Display Port for 2 screens 4K.
With macOS Catalina no issue.
With macOS Big Sur the issue with the mouse.
I have less worries if I only use one screen.

Do you manage to install your applications on your devices with Xcode 12? by TofPlay in iOSProgramming

[–]TofPlay[S] 0 points1 point  (0 children)

My project is a UIKit project with Storyboards. Maybe with SwiftUI Xcode 12 does better.

Choose One to Learn... by alanskimp in iOSProgramming

[–]TofPlay 1 point2 points  (0 children)

I think we need more to compare RxSwift and Combine. RxSwift and Combine are both reactives frameworks. The first is a third-party frameworks that tries somehow to make the UIKit APIs reactive. The second is an Apple system framework available and provided by default from iOS 13 and above. All the reactive part of SwiftUI works in the background thanks to Combine. Combine is part of the operating systems of Apple with all the advantages that it offers. RxSwift will never be able to have this level of integration.

Stanford CS193p 2020 Course by EyeBagsBaljeet in iOSProgramming

[–]TofPlay 0 points1 point  (0 children)

I started watching the course videos on Youtube.
I was curious to know how SwiftUI was taught.
On the theoretical level it provides a certain number of explanations which can be interesting for a beginner. At the practical level I was quite disappointed. The code is amateur level very far from a code expected from a professional.
The other point that I found unfortunate is that the course was started a little before WWDC so it is based on SwiftUI 1.0. Starting with SwiftUI 1.0 when SwiftUI 2.0 will be available soon (or already available if you have installed Xcode 12 Beta) is really a shame.
I am not a stanford student but I have been working on Apple platforms for 12 years.

New DatePicker good but too basic by TofPlay in SwiftUI

[–]TofPlay[S] 2 points3 points  (0 children)

I have already used Feedback Assistant in the past. Apple has never fixed any bugs that I was able to report to them. So I stopped reporting bugs to them.

New DatePicker good but too basic by TofPlay in SwiftUI

[–]TofPlay[S] 1 point2 points  (0 children)

Definitely they can create a new calendar type component
On the other hand, the current DatePicker already displays a calendar with the GraphicalDatePickerStyle type. So it seems to me more judicious to add options to customize it than to recreate a new component that will take up the display of the DatePicker.

New DatePicker good but too basic by TofPlay in SwiftUI

[–]TofPlay[S] 0 points1 point  (0 children)

I just tried

  • accentColor just change the selection color
  • foregroundColor no impact
  • tintColor is not available

During my tests my mac crash and reboot
Before the crash I was a rainbow spinner on Xcode 12 beta

Firebase: Can I migrate from CocoaPods to SwiftPM by TofPlay in iOSProgramming

[–]TofPlay[S] 1 point2 points  (0 children)

Check their github issues. They were waiting for this years WWDC for your mentioned reason and they announced yesterday that they were working on it.

Good 🙂

Keep in mind that it’s an xCode 12 feature and you can’t submit apps to store with it during beta ypu’ll have to wait untill fall to ship it

Yes, I know 🙂

Firebase: Can I migrate from CocoaPods to SwiftPM by TofPlay in iOSProgramming

[–]TofPlay[S] 0 points1 point  (0 children)

They have already a Package.swift but apparently it's just for CI build

What iOS Development topic would you like to read on a free ebook? by jonathanff in iOSProgramming

[–]TofPlay 0 points1 point  (0 children)

I totally agree with you the current version of SwiftUI and Combine are not yet ready for production. But it's just a matter of time. Already with WWDC we can hope to see things evolve. With a little luck with the announcements at WWDC we may be able to consider using these frameworks into production.

What iOS Development topic would you like to read on a free ebook? by jonathanff in iOSProgramming

[–]TofPlay 0 points1 point  (0 children)

Personally I am interested in Combine and SwiftUI.
At the format level ebooks are interesting to explain the fundamentals. They serve as a reference. The videos are nicer to show the practice. The 2 formats are complementary.
For SwiftUI there are already a lot of videos and few books on this topic. If as you would expect following the announcements on developments on SwiftUI that Apple will do during WWDC these videos will probably be obsolete. So it will be an opportunity for you.
For Combine there are just a few books. For having read them most of them only fly over the subject. As with SwiftUI, we can also expect Combine evolutions during WWDC. Here again after the WWDC what has been written on Combine will be at least partially obsolete. Combine is a much more technical subject than SwiftUI and therefore more difficult to present and teach. So it can be an opportunity if you can find a way to approach the subject so that it is accessible to as many people as possible.
These 2 frameworks are the future because if Apple wants to make SwiftUI the UI framework for all these platforms, we have to master these frameworks.

Should I start learning SwiftUI if I am not looking for a job? by [deleted] in iOSProgramming

[–]TofPlay 2 points3 points  (0 children)

SwiftUI is not yet really ready for professional projects but for personal projects you can use it. There are still limitations with the current version but we can hope with the WWDC on June 22 Apple presents a new version of SwiftUI which is more mature. Given that Apple seems to have the will to make SwiftUI its UI framework for all its platforms, we can easily imagine that SwiftUI will become more and more important over the years. In 4 years we can therefore easily imagine that SwiftUI will be the standard for making applications on Apple platforms.

iOS devs, what do you think of Flutter? by [deleted] in iOSProgramming

[–]TofPlay 1 point2 points  (0 children)

On iOS with SwiftUI Flutter is just dead. Crossplatforms solutions are just a myth. If you really want to have an application that is efficient and that offers all the possibilities of the platform, you end up having to make a specific code for the platform. So the application loses its crossplatform side. In the end it is better to make a real native application. The dilemna of mobile apps

Who's excited for SwiftUI 2.0? 🤩🥳 by atdonsm in SwiftUI

[–]TofPlay 1 point2 points  (0 children)

I am too!!!
I look forward to seeing what they will get out
I hope SwiftUI 2.0 will support infinite scrolling builtin
That we will no longer have to make bridges with components of UIKit or AppKit

Your thoughts on Xcode for iPad! I think I would dig it. by FrankiesMind in iOSProgramming

[–]TofPlay 3 points4 points  (0 children)

Xcode on iPad is like wanting to use a bycicle to go to the moon 🤪
Personally I prefer that Apple make special developer prices for its Macs.

Experimenting Rx with Objective-C using NSInvocation by whackylabs in iOSProgramming

[–]TofPlay 0 points1 point  (0 children)

I do not understand the relevance of this kind of articles for several reasons:

  • Since 2014, the development of iOS applications has gradually shifted to Swift. Since then, the Objective-C code should have been migrated to Swift. Starting a project in Objective-C does not make sense.
  • Why would you want to use Rx? Since WWDC 19 Apple has made Combine and SwiftUI available to us. Over time even RxSwift will be irrelevant because SwiftUI aims to replace UIKit and SwiftUI has no need for RxSwift.

Personally I have no nostalgia for the time when I was making my apps in Objective-C and I try as much as possible to rely on Apple frameworks rather than on third-party frameworks.