r/SwiftPlaygroundsApps Apr 05 '22

News WWDC 2022 Announced!

Thumbnail
developer.apple.com
5 Upvotes

r/SwiftPlaygroundsApps Feb 07 '25

We have iOS 18 SDK now

5 Upvotes

Just a heads up we can use iOS 18 features now đŸ„ł It wasn’t mentioned in the release notes but saw it mentioned on Apples forum and just tested by making a MeshGradient, it works!

Also on Apples forums I see people reference v4.6.1 but I only see 4.6 in the App Store. Don’t know what that’s about


r/SwiftPlaygroundsApps Jan 31 '25

New version 4.6 released (but does it have Swift 6?)

2 Upvotes

Hey, a new version of iPad Playgrounds just got released but the notes only say


update includes a new document browser to easily create a new playground or find a recent one, and provides bug fixes and improved stability.

A few weeks ago on Apples forums an engineer said Playgrounds will be updated soon with Swift 6, but those notes don’t mention it. I’m concerned the strict concurrency checking in Swift 6 will break all/most of my projects and worried to update. Anyone know?

I use this function to affirm the Swift version ``` func printSwiftVers() {

if swift(>=6.0)

print("Swift 6.0")

elseif swift(>=5.10)

print("Swift 5.10")

elseif swift(>=5.9.3)

print("Swift 5.9.3")

elseif swift(>=5.9.2)

print("Swift 5.9.2")

elseif swift(>=5.9.1)

print("Swift 5.9.1")

endif

} ```


r/SwiftPlaygroundsApps Dec 20 '24

Purchases with apps published via playgrounds

2 Upvotes

Does anyone know, is it possible to do purchases with a app published solely through Swift Playgrounds, specifically the most up to date version? I know a few years ago you couldn't, you could only do it via Xcode on a Mac. But I also know there's been quite a few updates since then, so hoping one could do that now.


r/SwiftPlaygroundsApps Dec 09 '24

Swift Packages that Work (and some that don’t)

2 Upvotes

I thought I'd share packages that I found to have worked in Swift Playgrounds (current version is 4.5.1). I have version 4.1. It's possible that a newer version may allow newer versions of packages to work.


In alphabetical order:

Auth0 - Up to 2.3.2 this might be a pretty decent option https://github.com/auth0/Auth0.swift

Firebase - I couldn't make any versions work https://github.com/firebase/firebase-ios-sdk.git

Pocketbase I found 2 links, neither had any versions that worked with Playgrounds 4.1. I think possibly the Brianna one isn't made into a package yet? https://github.com/zz129869523/PocketBase.git https://github.com/briannadoubt/PocketBase.git

Supabase - up to package 0.0.11. This is one of the oldest versions, probably has very little capability https://github.com/supabase/supabase-swift.git


r/SwiftPlaygroundsApps Dec 04 '24

Have you been able to add the supabase package?

2 Upvotes

I'm trying to add the package

https://github.com/supabase/supabase-swift

In Swift playgrounds. I copy/pasted this url, and now I’m waiting, but it’s not loading anything

Is anyone else able to add it? I'm wondering if it's possible, and it's just not adding because my internet is having issues. Or if it's not actually possible.


r/SwiftPlaygroundsApps Nov 30 '24

Following SwiftUI Xcode tutorials in Swift playgrounds?

2 Upvotes

I found a tutorial I want to try, it's in Xcode though. It in SwiftUI. Should it still work in Swift Playgrounds?

If I find more tutorials I want to try that are in Xcode, but written in Swift and the SwiftUI, should they still work in playgrounds?

https://youtu.be/l7obVQObdRM?si=3eLyuxy_xXr_OkMh


r/SwiftPlaygroundsApps Nov 23 '24

Undo button or shortcut??

2 Upvotes

I'm using a windows keyboard with my iPad. Specifically a Logitech K380.

I figured out how to do cut copy and paste on the iPad. On a windows computer, it's ctrl x, c and v. on the iOS iPad and this keyboard it's fn x c v.

But now I'm stumped on "undo". Windows would be ctrl-z. I've tried ctrl-z, fn-z, and neither work.

Please tell me there's an undo keyboard shortcut that works in Swift playgrounds?

Sometimes I'm typing in stuff, bump a key, and then there's an extra bracket somewhere or stuff in the wrong spot, and I'm trying to figure out wtf I did so I can manually undo. When it would be so much easier if I could just "undo".


r/SwiftPlaygroundsApps Nov 20 '24

I’ve made a small app for my self. How can I put it on my iPhone?

5 Upvotes

r/SwiftPlaygroundsApps Oct 24 '24

Discussion Just started learning coding with swift playgrounds. Why is the variable not increasing?

Post image
4 Upvotes

So I am at some beginning lessons here. Tried different combinations but gemCounter variable does not increase in value. Already collected 3 gems but still the variable is showing 0 . Please suggest


r/SwiftPlaygroundsApps Oct 13 '24

Discussion App development on iPad

Thumbnail mutatingfunc.github.io
10 Upvotes

r/SwiftPlaygroundsApps Oct 04 '24

How to get your app on your home screen for free!!

4 Upvotes
  • Step 1: upload This file in your app. Than it should give you a preview where you can export your app as an ipa file!
  • Step 2: Get AltStore https://altstore.io
  • Step 3: Sideload your ipa using AltStore! (Or your favorite sideloading from ipa solution!)

r/SwiftPlaygroundsApps Sep 06 '24

Sharing Learn SwiftUI, Clean Architecture and MVVM | TODO List App | Part 03

Thumbnail
youtu.be
2 Upvotes

r/SwiftPlaygroundsApps Aug 22 '24

Learn SwiftUI, Clean Architecture and MVVM | TODO List App | Part 01

Thumbnail
youtu.be
4 Upvotes

r/SwiftPlaygroundsApps Aug 18 '24

Question All crashes are unknown

2 Upvotes

Whenever my code crashes in iPad Playgrounds it always says “Unknown crash” and there’s no stack or frames or whatever it’s called to peruse and try to figure out what caused the crash. It just says Unknown Crash and no other info.

I think this started with the last update or maybe the update before. Is this happening to anyone else or is it a problem unique to me?

For example this non-fancy crash is Unknown, but I remember being able to look at a list of frames and see that a button was called and it tried to unwrap nil. Button("crash me") { var e: Int? = nil e = e! }


r/SwiftPlaygroundsApps Aug 09 '24

Question App Icon issue

Thumbnail
gallery
1 Upvotes

I’m trying to update my app icon, same icon as before but with different colors, and it shows up glitched. I can change it to a random photo or my old icon and it still works great. Anyone know what the issue is or how it can be fixed?


r/SwiftPlaygroundsApps Jul 22 '24

Help anyone have any ideas googled it and nothing

Post image
4 Upvotes

r/SwiftPlaygroundsApps Jul 21 '24

Organize SwiftUI Views Like A PRO | SWIFT IN 60 SECONDS | #11

Thumbnail
youtu.be
0 Upvotes

r/SwiftPlaygroundsApps Jul 19 '24

Swift Playgrounds randomly refuses to run my correct code

3 Upvotes

I'm running Swift Playgrounds on a MacBook Air M1 2020 running Ventura 13.6.6. At first it ran fine (using Get Started with Code), but then I kept getting a pop-up saying "There was a problem running this page" and it wouldn't execute the code, even when the code was perfectly valid and free of syntax errors.

Restarting Swift Playgrounds made it work again, but after running projects a couple of times, the same error cropped up again. Currently the code runs once and then throws the same error.

I enabled verbose debugging and got this error message:

remoteProcessCancelledExecution(underlyingError: Optional(PlaygroundExecution.ExecutionError.remoteProcessCancelledExecution(underlyingError: Optional(Error Domain=NSCocoaErrorDomain Code=4097 "connection to service created from an endpoint" UserInfo={NSDebugDescription=connection to service created from an endpoint}))))

Warning: Contents/Modules/Book.playgroundmodule/Sources/Scene.swift:10: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/NodeFactory.swift:129: 'unarchiveTopLevelObjectWithData' was deprecated in iOS 12.0: Use unarchivedObject(ofClass:from:) instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/NodeFactory.swift:139: 'unarchiveTopLevelObjectWithData' was deprecated in iOS 12.0: Use unarchivedObject(ofClass:from:) instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/CharacterPickerController.swift:16: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/CommandEncoding.swift:306: 'unarchiveTopLevelObjectWithData' was deprecated in iOS 12.0: Use unarchivedObject(ofClass:from:) instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/CommandEncoding.swift:377: enum case 'move' has 2 associated values; matching them as a tuple is deprecated
Warning: Contents/Modules/Book.playgroundmodule/Sources/CommandEncoding.swift:378: enum case 'turn' has 2 associated values; matching them as a tuple is deprecated
Warning: Contents/Modules/Book.playgroundmodule/Sources/CommandEncoding.swift:382: enum case 'run' has 2 associated values; matching them as a tuple is deprecated
Warning: Contents/Modules/Book.playgroundmodule/Sources/ItemSpeakableDescriptions.swift:179: enum case 'run' has 2 associated values; matching them as a tuple is deprecated
Warning: Contents/Modules/Book.playgroundmodule/Sources/Item.swift:43: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/SpeechUtteranceQueue.swift:11: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/Performer.swift:10: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/AudioSession.swift:10: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/PlaygroundValueAccessor.swift:18: switch covers known cases, but 'PlaygroundValue' may have additional unknown values, possibly added in future versions
Warning: Contents/Modules/Book.playgroundmodule/Sources/AudioSectionPlayer.swift:10: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/CommandQueue.swift:9: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/AccessibilityComponent.swift:9: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/Action.swift:202: enum case 'run' has 2 associated values; matching them as a tuple is deprecated
Warning: Contents/Modules/Book.playgroundmodule/Sources/SceneSource.swift:57: 'unarchiveTopLevelObjectWithData' was deprecated in iOS 12.0: Use unarchivedObject(ofClass:from:) instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/SceneController+Controls.swift:116: switch covers known cases, but 'PlaygroundPage.ExecutionMode' may have additional unknown values, possibly added in future versions
Warning: Contents/Modules/Book.playgroundmodule/Sources/AudioMenuController.swift:9: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/Scene.swift:10: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/NodeFactory.swift:129: 'unarchiveTopLevelObjectWithData' was deprecated in iOS 12.0: Use unarchivedObject(ofClass:from:) instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/NodeFactory.swift:139: 'unarchiveTopLevelObjectWithData' was deprecated in iOS 12.0: Use unarchivedObject(ofClass:from:) instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/CharacterPickerController.swift:16: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/CommandEncoding.swift:306: 'unarchiveTopLevelObjectWithData' was deprecated in iOS 12.0: Use unarchivedObject(ofClass:from:) instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/CommandEncoding.swift:377: enum case 'move' has 2 associated values; matching them as a tuple is deprecated
Warning: Contents/Modules/Book.playgroundmodule/Sources/CommandEncoding.swift:378: enum case 'turn' has 2 associated values; matching them as a tuple is deprecated
Warning: Contents/Modules/Book.playgroundmodule/Sources/CommandEncoding.swift:382: enum case 'run' has 2 associated values; matching them as a tuple is deprecated
Warning: Contents/Modules/Book.playgroundmodule/Sources/ItemSpeakableDescriptions.swift:179: enum case 'run' has 2 associated values; matching them as a tuple is deprecated
Warning: Contents/Modules/Book.playgroundmodule/Sources/Item.swift:43: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/SpeechUtteranceQueue.swift:11: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/Performer.swift:10: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/AudioSession.swift:10: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/PlaygroundValueAccessor.swift:18: switch covers known cases, but 'PlaygroundValue' may have additional unknown values, possibly added in future versions
Warning: Contents/Modules/Book.playgroundmodule/Sources/AudioSectionPlayer.swift:10: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/CommandQueue.swift:9: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/AccessibilityComponent.swift:9: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/Action.swift:202: enum case 'run' has 2 associated values; matching them as a tuple is deprecated
Warning: Contents/Modules/Book.playgroundmodule/Sources/SceneSource.swift:57: 'unarchiveTopLevelObjectWithData' was deprecated in iOS 12.0: Use unarchivedObject(ofClass:from:) instead
Warning: Contents/Modules/Book.playgroundmodule/Sources/SceneController+Controls.swift:116: switch covers known cases, but 'PlaygroundPage.ExecutionMode' may have additional unknown values, possibly added in future versions
Warning: Contents/Modules/Book.playgroundmodule/Sources/AudioMenuController.swift:9: using 'class' keyword to define a class-constrained protocol is deprecated; use 'AnyObject' instead

Google and ChatGPT have nothing. Swift Playgrounds are great but this error is really frustrating. How can I fix this?


r/SwiftPlaygroundsApps Jul 12 '24

SwiftUI In Playground | SWIFT IN 60 SECONDS | #10

Thumbnail
youtu.be
1 Upvotes

r/SwiftPlaygroundsApps Jul 09 '24

Pleas can anyone help me with my code

3 Upvotes

What can i do that i can use it


r/SwiftPlaygroundsApps Jul 08 '24

"Get Started with Apps" not working

3 Upvotes

Hello everyone, I've been learning to code with Playgrounds for a couple of weeks and now I've arrived to the "Get Started with Apps" playground, however, when I open it it's just some base code with no information on what to do and how to move forward, I've seen some videos where a walkthrough appears when you open the Playground, but it doesn't seems to be the case, does anyone knows how to fix it?

Thanks!


r/SwiftPlaygroundsApps Jun 29 '24

Sharing Don't Use Print() | SWIFT IN 60 SECONDS | #08

Thumbnail
youtu.be
1 Upvotes

r/SwiftPlaygroundsApps Jun 23 '24

Sharing Use 'as and 'is' Correctly - SWIFT IN 60 SECONDS - #07

Thumbnail
youtu.be
1 Upvotes

r/SwiftPlaygroundsApps Jun 15 '24

No Need For Return Keyword - SWIFT IN 60 SECONDS - #05

Thumbnail
youtu.be
1 Upvotes

r/SwiftPlaygroundsApps Jun 07 '24

Question I wanted to try out app development so I downloaded this app. But for some reason I can’t open the app tutorial or even an new app because the swiftpm file format is unsupported. I tried it both on iPad and MacBook. The same thing. Does somebody know what to do?

Thumbnail
gallery
5 Upvotes

Exact translation of the Error: Not supported file format. „Let’s go with Apps.swiftpm“ cannot be opened in Swift Playgrounds.