Post

Replies

Boosts

Views

Activity

Build input file cannot be found
I have been following this tutorial: https://developer.apple.com/tutorials/app-dev-training/using-stacks-to-arrange-views and after completing step 2 where it states to "Refactor > Rename" the ContentView file to MeetingView, I attempted to "Resume" the preview. When I do so, I get this error: Build input file cannot be found: '<path>/Scrumdinger/Shared/ContentView.swift' Apparently it is trying to look for the old name of the file. How can I resolve this issue? I am using XCode 13.
1
0
2.1k
Jul ’22
Type Properties in Extensions
I am new to Swift, and I have been following a tutorial on Creating a Card View. In Section 2, step 3, it directs the user to add an extension to the DailyScrum struct: struct DailyScrum {   var title: String   var attendees: [String]   var lengthInMinutes: Int   var theme: Theme } extension DailyScrum {   static let sampleData: [DailyScrum] =   [     DailyScrum(...),     DailyScrum(...), DailyScrum(...)   ] } From my understanding, the constant sampleData is a stored type property, yet I read that extensions can only add computed type properties. Can someone help me understand what sampleData is, and why it can be used in an extension?
2
0
329
Jul ’22