Category "swift"

SwiftUI List Button with Disclosure Indicator

I have a SwiftUI view that consists of a list with some items. Some of these are links to other screens (so I use NavigationLink to do this) and others are acti

Create a static library with React dependency

I created a library that uses the native navigation controller to navigate through react and native screens. The library is written in Swift and contains some o

How to use "HEVC with Alpha channel" videos in SceneKit?

At WWDC 2019, Apple announced that it was now handling HEVC with Alpha in iOS, and state that it could be used in SceneKit. I've been trying for hours to make

Is it complusory to use "in" keyword in closure? If no then what is the syntax wise difference between closure and computed property in swift?

In swift use of get and set is not compulsory and if use of "in" in closure is also not compulsory then how to differentiate a closure and computed property? Li

Scene kit shape distorted

We built an iOS app to render 3D objects using Scene kit. We are plotting based upon coordinates(Vertices) received and populating our scene view inside Table c

Getting correct date from FSCalendar

I have been looking around a lot but found no real solution to this one. I use FSCalendar and didSelectDate is giving the wrong date. The only fix for this that

Implementing Codable for UIColor

Is it possible to implement the Encodable and Decodable properties for UIColor When I try to add a Decodable extension I get an error extension UIColor : Deco

iOS file patterns: The `source_files` pattern did not match any file

I am trying to create a CocoaPod and when I try pod lib lint there's an error about ERROR | [iOS] file patterns: Thesource_filespattern did not match any file.

use systemSound from SystemSoundID for UNNotificationSound

I am trying to add a sound to my UNNotification. Instead of my own custom sound or the default sound, I would like to use one of the iOS SystemSounds in AVFoun

Segmentation fault: 11 (in target 'DKImagePickerController' from project 'Pods')

I'm developing IOS app from flutter. Everything working fine, suddenly I have received error SwiftCodeGeneration normal arm64 (in target 'DKImagePickerControlle

Implement dark mode switch in SwiftUI App

I'm currently looking into Dark Mode in my App. While Dark Mode itself isn't much of a struggle because of my SwiftUI basis i'm struggling with the option to se

XCUITest ProgressView identifier hardcoded to "In progress" when within a Button

When creating a ProgressView and using .accessibilityIdentifier or a standard label, UI tests are able identify it. The view: ProgressView().accessibilityIdenti

How to view PDF from Firebase Storage - SwiftUI PDFVIEW

I am having some issues trying to display a PDF which is stored in Firebase Storage in my SwiftUI app. I have successfully done the following; Uploaded a PDF fi

Read and write permission for user selected folder in Mac OS app?

I am developing MAC OS app which have functionality to create file on the behalf of your. First user select folder for storing file (One time at start of app) a

Can I use MVVM without data binding?

I am trying to use MVVM. Upon reading some blogs on MVVM, I found them using data binding techniques like Rx, KVO, Boxing etc. Following are my classes for vali

Why is Swift compiler complaining about circular reference when I comment out seemingly unrelated code?

Creating a brand new macOS Command Line Tool project in Xcode Version 13.3 (13E113), and replacing the contents of main.swift with the following code: import Fo

usleep in Swifter degrades overtime

I have the following server: import SwiftUI import Swifter @main struct MacInputServer: App { let server: HttpServer; var body: some Scene { W

Swift convert unix time to date and time gives incorrect year

I am getting time string from server but when I convert it to local time its giving incorrect year like 52635 My code is- if let dateVal = (model.insert_date){

SwiftUI - Animations triggered inside a View that's in a list doesn't animate the list as well

I have a List that's displaying two Views of the same type. When you tap on one of the views, they change their height with an animation. However, the List tho

How to hide header and footer in WKWebView using Js and ios-14

How to hide header and footer in WKWebView in swift in IOS 14 I am using below code for loadiing thr website inside webview. webview.load(URLRequest.init(url: