Another great video. Do you have an example of a core data and a form supporting a many-to-many relationship?
@LeoJunquera Жыл бұрын
Great tutorial. Do you have a many to many example? One where you might have to keep additional in the intermediate table? Like Recipe/Ingredient with an intermediate table for amount, or User/Rating/Restaurant, etc.
@cliffspencer3 жыл бұрын
Paul, shouldn't those convenience properties be called unwrapped* as you are actually unwrapping the optional?
@twostraws3 жыл бұрын
I went back and forward on the naming a few times, because although I'm unwrapping them I'm not *just* unwrapping them - it's not like a force unwrap, but instead some wrapper code that provides a default value. I've used unwrapped* elsewhere a few times, so it's not like I'm firmly committed to the choice 🙂
@mutualrespect44112 жыл бұрын
@@twostraws I went with unwrappedWrapped
@yanhao-li2 жыл бұрын
Love the dogs!
@uniquecrafter44322 жыл бұрын
If I want to store URLs and UUIDs in Core Data, what should I nil coalesce to when creating those computed properties? A new empty URL instance (i.e URL(fileWithPath: "") and a new UUID() instance respectively?
@LeoJunquera Жыл бұрын
Couldn't you have the classes automatically created and create an extension class for the object and still use Codegen = class definition?
@isthorify2 жыл бұрын
Thx for this. I followed this tutorial using swift playground on the iPad. It works fine, but is it possible to set Contraints for Entity manually, not using Xcode ?
@AndyJMacLeod2 жыл бұрын
Why did Paul call those variables wrappedShortname (etc) rather than unwrappedShortname? Thanks.
@АльфредГордан Жыл бұрын
OMG. this video is mind-blowing
@midlifematt3 жыл бұрын
I am in the mood for candy now 🍬… those dogs though, wonderful 😊 Love the videos 👍🏻
@tommy95762 жыл бұрын
Such a great tutorial, you helped me so often!
@RoustamManookian Жыл бұрын
Hi, how to fetch only the Countries without the relationship entities?
@hamidehsheikh2619 Жыл бұрын
Such a great tutorial, and you are the best teacher. Thank you so much🥰
@kafran2 жыл бұрын
Wouldn't it be better to put the wrapped properties as an Extension in another file so it doesn't get rewritten?
@tiIIus2 жыл бұрын
Thank you, that's such great tutorial!
@beanberg Жыл бұрын
Thanks so much for your tutorial! It helped me lots
@ec92009y2 жыл бұрын
How many treats do they get everyday?
@Alshafi2 жыл бұрын
how to clean all the errors and warnings?
@ColeHoney-e5c Жыл бұрын
Command + Shift + K
@devsmond3 жыл бұрын
How can I create data and display it when the app starts, without having to click the button first?
@nabs3 жыл бұрын
Anywhere where your code already runs without an explicit interaction (like a button press) would work. An example would be the ContentView’s initializer, or in CoreDataProjectApp before ContentView is initialized. Just remember to remove that code after it runs once, otherwise you’d be attempting to create and save that data on each run
@devsmond3 жыл бұрын
@@nabs Thank you for this! I tried messing around with the initializer before asking this question but I can't get a full grasp on how to use it with my data model.
@梁非凡-h6i2 жыл бұрын
constraints failed to work in Xcode Version 14.1 beta (14B5024h) sometimes, I added constraints for shortName but I can still see a bunch of entries with the same short name, I even downloaded your project 12 from github and directly run on my mac, still no luck. But previously it worked perfectly for singers with same names, really strange.
@iurii5132 жыл бұрын
Same thing here. Did you get a solution?
@JonSweeney262 жыл бұрын
@@iurii513 Be sure to update the Persistence file generated in Xcode 14.0+. I added the self.container.viewContext.mergePolicy = NSMergePolicy.mergeByPropertyObjectTrump to line 55, after the container...MergesChangesFromParent = true in the initializer.
@aleixplanasguibas2 жыл бұрын
@@JonSweeney26 what do you mean to line 55? It isn't working for me and I can't find any information regardless the merge policy getting old. Could you be more specific? Thanks!!
@maxmaxmaxmaxmaxmaxmaxmaxmax1 Жыл бұрын
To your DataController file, add the following code after your closing brace for container.loadPersistentStores (probably line 15) self.container.viewContext.mergePolicy = NSMergePolicy.mergeByPropertyObjectTrump
@jlleee Жыл бұрын
I thought I had the same but I missed the part where he added try? moc.save() at the end
@seungjunlee002 жыл бұрын
Thanks you sooo much foir this awesome great video!
@sirpoohbehr47932 жыл бұрын
Insanely helpful tyvm :D
@udesai20113 жыл бұрын
Is there a working code for download available?
@DaveyonMayne-ok2 жыл бұрын
Hola. Could you make a video on how to update/delete an entity?
@MoAdel922 жыл бұрын
He did before
@MoAdel922 жыл бұрын
Revise bookworm series
@xingguohuang4487 Жыл бұрын
@@MoAdel92Could you please share the link? I looked everywhere but couldn’t find it.😂
@DavidNitzscheBell2 жыл бұрын
Well, well, well....Who would have thought that I'd learn something about the origin of candy bars in a video about SwiftUI???? I was all ready to "correct" you about the origin of Mars, Twix and KitKat (I'm from the US and, of course, *everything* was invented in the US, right? ) but life has taught me to look things up first. And, lo and behold, invented in UK!!! So, at least I can blame the UK for being the US's origin story for fascination with junk food. ;)