# \#playgrounds

**URL:** https://forums.swift.org/tag/playgrounds/618.md

[Latest](https://forums.swift.org/latest.md) · [Categories](https://forums.swift.org/categories.md) · [Tags](https://forums.swift.org/tags.md)

---

## [Init accessors fail to parse in playgrounds](https://forums.swift.org/t/init-accessors-fail-to-parse-in-playgrounds/79329)

<div class="topic-metadata">

**Author:** [@tdrraluca](https://forums.swift.org/u/tdrraluca)\
**Replies:** 0\
**Last updated:** [April 17, 2025, 2:06pm UTC](https://forums.swift.org/t/init-accessors-fail-to-parse-in-playgrounds/79329 "2025-04-17T14:06:10Z")

</div>

Hi, Experimenting with init accessors I ran into the issue of not beeing able to use them from Xcode playgrounds. A simple newly created playground containing only the Angle struct example from the init accessors propos…

---

## [Is there something similar to playgrounds when using VS Code?](https://forums.swift.org/t/is-there-something-similar-to-playgrounds-when-using-vs-code/78079)

<div class="topic-metadata">

**Author:** [@theundergroundsorcerer](https://forums.swift.org/u/theundergroundsorcerer)\
**Replies:** 2\
**Last updated:** [February 25, 2025, 10:50am UTC](https://forums.swift.org/t/is-there-something-similar-to-playgrounds-when-using-vs-code/78079 "2025-02-25T10:50:23Z")

</div>

Playgrounds are wonderful tool when doing explorative programming. Is there something similar when using VS Code? Thanks.

---

## [Why is there a "Type of expression is ambiguous without a type annotation." error when using a ternary operator on inferred function types in Swift?](https://forums.swift.org/t/why-is-there-a-type-of-expression-is-ambiguous-without-a-type-annotation-error-when-using-a-ternary-operator-on-inferred-function-types-in-swift/77306)

<div class="topic-metadata">

**Author:** [@schifano](https://forums.swift.org/u/schifano)\
**Replies:** 10\
**Last updated:** [January 21, 2025, 9:18am UTC](https://forums.swift.org/t/why-is-there-a-type-of-expression-is-ambiguous-without-a-type-annotation-error-when-using-a-ternary-operator-on-inferred-function-types-in-swift/77306 "2025-01-21T09:18:45Z")

</div>

Hello - I'm a first time poster here so please let me know if I'm in the right category. I posted this question on StackOverflow today and it was suggested I post here for further discussion. See original question here. …

---

## [How does iPad Playgrounds have a different compiler?](https://forums.swift.org/t/how-does-ipad-playgrounds-have-a-different-compiler/76773)

<div class="topic-metadata">

**Author:** [@trochoid](https://forums.swift.org/u/trochoid)\
**Replies:** 1\
**Last updated:** [December 20, 2024, 7:30am UTC](https://forums.swift.org/t/how-does-ipad-playgrounds-have-a-different-compiler/76773 "2024-12-20T07:30:25Z")

</div>

It seems iPad Playgrounds somehow has a different compiler than everywhere else. For example the following code in the current iPad Playgrounds 4.5.1 which uses Swift 5.10 causes a mysterious floating error… enum EZIO20…

---

## [Possible to use macros in Swift Playgrounds?](https://forums.swift.org/t/possible-to-use-macros-in-swift-playgrounds/69055)

<div class="topic-metadata">

**Author:** [@NSExceptional](https://forums.swift.org/u/NSExceptional)\
**Replies:** 2\
**Last updated:** [November 8, 2024, 10:22pm UTC](https://forums.swift.org/t/possible-to-use-macros-in-swift-playgrounds/69055 "2024-11-08T22:22:16Z")

</div>

And if not, is this the first Swift language feature that cannot be used from Playgrounds?

---

## [WKwebView in Swift Playgrounds(SwiftUI)?](https://forums.swift.org/t/wkwebview-in-swift-playgrounds-swiftui/67718)

<div class="topic-metadata">

**Author:** [@V205](https://forums.swift.org/u/V205)\
**Replies:** 1\
**Last updated:** [October 7, 2023, 3:57am UTC](https://forums.swift.org/t/wkwebview-in-swift-playgrounds-swiftui/67718 "2023-10-07T03:57:47Z")

</div>

How do I use WKwebView in Swift Playgrounds(SwiftUI App) I tried to follow some tutorials but it seems like I am missing a critical file….. Info: iPad Swift Playgrounds App Thank you! I don’t know if this is the r…

---

## [In-App Libraries for Swift Playgrounds on iPad](https://forums.swift.org/t/in-app-libraries-for-swift-playgrounds-on-ipad/67241)

<div class="topic-metadata">

**Author:** [@toph42](https://forums.swift.org/u/toph42)\
**Replies:** 0\
**Last updated:** [September 12, 2023, 10:56am UTC](https://forums.swift.org/t/in-app-libraries-for-swift-playgrounds-on-ipad/67241 "2023-09-12T10:56:23Z")

</div>

Since the addition of App projects in Swift Playgrounds 4 it’s been easy to use libraries in Swift packages hosted online in your Apps, but it hasn’t been easy or clear how to create libraries for reuse using Swift Playg…

---

## [SPM Binary Packages + Swift Playgrounds on iPad](https://forums.swift.org/t/spm-binary-packages-swift-playgrounds-on-ipad/62916)

<div class="topic-metadata">

**Author:** [@Colin\_Cornaby](https://forums.swift.org/u/Colin_Cornaby)\
**Replies:** 2\
**Last updated:** [February 6, 2023, 3:22am UTC](https://forums.swift.org/t/spm-binary-packages-swift-playgrounds-on-ipad/62916 "2023-02-06T03:22:29Z")

</div>

I'm trying to pull down a binary package to an iPad running Swift Playgrounds, and I get an error that "unzip" cannot be found. Guessing it can't unzip the package, but at a broader level, downloading a binary package to…

---

## [List combined with NavigationLink for multiple destinations in playgrounds](https://forums.swift.org/t/list-combined-with-navigationlink-for-multiple-destinations-in-playgrounds/59722)

<div class="topic-metadata">

**Author:** [@dartmeadow](https://forums.swift.org/u/dartmeadow)\
**Replies:** 2\
**Last updated:** [September 5, 2022, 6:14pm UTC](https://forums.swift.org/t/list-combined-with-navigationlink-for-multiple-destinations-in-playgrounds/59722 "2022-09-05T18:14:15Z")

</div>

In the tail end of my paste in you will see I’m trying to achieve multiple view destinations according to currently selected list item Any help?

---

## [Giving functionality to a plus button](https://forums.swift.org/t/giving-functionality-to-a-plus-button/58463)

<div class="topic-metadata">

**Author:** [@DegexRJ](https://forums.swift.org/u/DegexRJ)\
**Replies:** 7\
**Last updated:** [July 11, 2022, 6:35pm UTC](https://forums.swift.org/t/giving-functionality-to-a-plus-button/58463 "2022-07-11T18:35:44Z")

</div>

Hi, I am new to swift and making apps and I’m trying to make my ‘plus’ button create a whole new stack in my code, so that when the plus button is pressed it sets of some code that inserts a new section. I’m not sure if …

---

## [PlaygroundTester - running tests for Swift Playgrounds 4 apps](https://forums.swift.org/t/playgroundtester-running-tests-for-swift-playgrounds-4-apps/55433)

<div class="topic-metadata">

**Author:** [@Losiowaty](https://forums.swift.org/u/Losiowaty)\
**Replies:** 0\
**Last updated:** [February 18, 2022, 9:18pm UTC](https://forums.swift.org/t/playgroundtester-running-tests-for-swift-playgrounds-4-apps/55433 "2022-02-18T21:18:10Z")

</div>

When Apple showed Swift Playgrounds 4 with the possibility of developing and publishing apps entirely on the iPad I think I'm not gonna make too huge a leap by saying that some people were delighted with the opportunity, …

---

## [Async/await in Playgrounds?](https://forums.swift.org/t/async-await-in-playgrounds/54145)

<div class="topic-metadata">

**Author:** [@dynamist](https://forums.swift.org/u/dynamist)\
**Replies:** 12\
**Last updated:** [December 24, 2021, 8:17pm UTC](https://forums.swift.org/t/async-await-in-playgrounds/54145 "2021-12-24T20:17:18Z")

</div>

func sampleFunc() async { // body } @main struct MainApp { static func main() async { await sampleFunc() } } The bare-minimum examples of initiating async calls apparently rely on wrapping it in som…
