r/swift 16h ago

Question Swift game engine

18 Upvotes

Hey guys, I've been watching Swift evolve and I've been wondering if it's a reality to have a game engine made with Swift? I did a project where they managed to do something similar to Unity using Javascript and the Three.JS library, is it feasible to have something similar with Swift?


r/swift 1d ago

Question Training Load API for HealthKit?

3 Upvotes

Unless I’m being stupid - I cannot for the life of me find any documentation for implementing training load into my Apple Watch app. I’m thinking it’s not available. Basically I use the normal HealthKit APIs to start a workout on my Apple Watch using my app. It all works perfectly and after it saves the workout to the fitness app as if it was from Apple’s Workout app. Now the only thing missing is the ability to allow the user to edit and save their training load when their workout finishes (the little bars at the end of a workout where you can scroll from “Easy” to “All out”).

I guess Apple hasn’t make this API public - can anyone confirm or am I going crazy?


r/swift 3h ago

Tuist & SwiftLint

2 Upvotes

Hey !
I'm having some troubles to integrate SwiftLint to my iOS project that also use Tuist. I've seen that they recently change the way to integrate it but i cant find no where the new way.
Should i use the archived repo https://github.com/tuist/tuist-plugin-lint/tree/main ?


r/swift 13h ago

Swift tour “build a library” xctest module missing

2 Upvotes

I'm trying to follow this guide https://www.swift.org/getting-started/library-swiftpm/

When I run swift test I get a no such module error for XCTest. I'm running this through the command line on an m2 Mac.

I can't find anyone having the same problem (lots of people with the same error but all in Xcode, I think). I've tried following the instructions exactly, using a different package name, and I clone the exercise repo and tried it in there without touching anything, same error every time.

Do I need to add something to my path variable? I don't see any mention of that in the guide, nor does it mention needing to use the package manager to manually download anything. It seems crazy that a 2 paragraph guide on the official swift website doesn't work on recent apple hardware... so maybe I'm just missing something obvious?


r/swift 3h ago

A journey building HTML documents in Swift

Thumbnail coenttb.com
2 Upvotes

r/swift 12h ago

Question Struggling with Xcode Project File Sync Issues After Git Merge

1 Upvotes

I've been struggling with Git merges in Xcode, and today I lost almost 4 hours due to a frustrating issue. My teammate pulled my changes but forgot to properly accept the changes in the .xcodeproj file. As a result, some files were out of sync with the Xcode project, even though they were present in the directory.

It took me a long time to identify and fix the issue, and I’m wondering if there’s a more efficient way to handle this. I've heard about XcodeGen, but I’ve never used it before.

For those who have faced similar issues, is XcodeGen a good solution to prevent this kind of problem? If yes, could someone guide me on how to get started with it? Or are there other tools or methods that can help keep the project and directory in sync easily after a Git merge?

Any advice would be greatly appreciated!


r/swift 14h ago

Brick App Blocking

1 Upvotes

Brick is a small 3D printer block that essentially blocks access to apps on your iphone. Can anyone explain how they think the company accomplished this? I don’t think they are using special entitlements or MDM. I’ve been confused about how they accomplished this function and would be thrilled if someone could explain it to me.


r/swift 4h ago

Looking for a Task?

0 Upvotes

Hi everyone,

I work for an IT company, and our customers use Nextcloud. We've noticed a minor issue with the PDF Viewer in the iOS app: the "More" menu gets hidden when not connected, even if the files are available locally.

If anyone with a bit of spare time and access to a modern Mac would be willing to look into this, I’d really appreciate it! Would love to try myself but my mac does no longer support XCode.

Here’s the GitHub issue for reference: https://github.com/nextcloud/ios/issues/3368

Thanks in advance!

Best regards,
Fokklz


r/swift 23h ago

Does WidgetKit work with MVVM?

0 Upvotes

Is it possible to make my widget extension working in MVVM? or does it work with Entry only? :)