@EnvironmentObject Explained in SwiftUI | iOS 17

แชร์
ฝัง
  • เผยแพร่เมื่อ 14 ต.ค. 2023
  • Confused about how @EnvironmentObject works? We've got you covered!
    🔥Become a member for UNLIMITED ACCESS
    www.stephancodes.com/plans-pr...
    🔥 iOS App Templates:
    www.stephancodes.com/shop
    🔴@State vs @Binding video:
    • NEVER Confuse @State v...
    🔴@StateObject vs @ObservedObject video:
    • DON'T Make this MISTAK...
    🔴 FREE Threads Clone SwiftUI Course:
    appstuff.teachable.com/p/swif...
    🔴 FREE Instagram Course with SwiftUI:
    • 🔴 Build Instagram With...
    🔴Navigation Stacks:
    • This NEW SwiftUI Featu...
    🖥️ ONLINE COURSES & APPS
    👉 Pro Courses:
    www.stephancodes.com/videos
    👉 FREE UBER SwiftUI Course
    • 🔴 Let's Build UBER wit...
    👉 FREE Twitter SwiftUI Course
    • 🔴 Let's Build Twitter ...
    📺 Social Media:
    Instagram - @stephan.dowless
    Instagram - @appstuffllc
  • วิทยาศาสตร์และเทคโนโลยี

ความคิดเห็น • 17

  • @_Astr_
    @_Astr_ 9 หลายเดือนก่อน +10

    Good stuff! 👍 Can you make a video about @Observable / @Bindable and how can we use @Environment in iOS 17?

  • @sergiocaplan1168
    @sergiocaplan1168 4 หลายเดือนก่อน

    Clear and concise! Thank you

  • @elduverx
    @elduverx 9 หลายเดือนก่อน +2

    "uno mas tiempo " i love that jajajaj

  • @faiazrahman1470
    @faiazrahman1470 หลายเดือนก่อน

    Great watch!

  • @user-pt2tz2hx9b
    @user-pt2tz2hx9b 9 หลายเดือนก่อน +1

    Hello, thank you for the content you create. Could you make a video about application modularity? I would love to learn how to break down applications into modules, and I'd prefer to learn it from you.

  • @filipp7236
    @filipp7236 4 หลายเดือนก่อน

    Thanks for the video. What if I have two View Models? One for using timers and other for playing sound.

  • @rahmonali7
    @rahmonali7 9 หลายเดือนก่อน

    As always best explanation. Actually, I am a diamond member on your website and I followed your networking masterclass which the course is awesome. There you didn’t use Environment object I wonder if you could explain us how to use environment object in that project because there you used protocol and service. It is kind of complicated for me to implement that project with Environment. And I would like to ask you that can we use multiple environment for multiple view model? Could you please explain that for us?

  • @oscarmartinez-pc1nj
    @oscarmartinez-pc1nj 4 หลายเดือนก่อน +1

    where do you get your coffee from?

  • @xtu373
    @xtu373 9 หลายเดือนก่อน +1

    When UIKit videos are coming? Like building apps clone with UIKit instead of SwiftUI

    • @iLoveAppl3947
      @iLoveAppl3947 5 หลายเดือนก่อน

      UIKit is sinking so what's the point of making clones with an old framework?

    • @xtu373
      @xtu373 5 หลายเดือนก่อน

      @@iLoveAppl3947 Why not? SwiftUI is just sugar. Most of the companies/start-up still uses UIKIT instead of SwiftUI.

  • @BradCaldwellAuburn
    @BradCaldwellAuburn 8 หลายเดือนก่อน

    Mine just says cannot find 'viewModel' in scope. Why is this environmentObject thing so freaking buggy. I have wasted hours trying to find an answer to this one stupid problem. It isn't seeing its own environmentObject that I'm supposed to use.
    Fix: I had to pass the private thing as a object down to the subsections of code below the main code. Doesn't seem like much of a fix, cause if it is an "environment" variable, you'd think it would be available in the background environment, not so picky that it can't even see itself in the same exact Swift file. Jeez.

    • @kennethcoker4663
      @kennethcoker4663 8 หลายเดือนก่อน

      I build this and it runs fine in the simulator but crashes ever time on the canvas, all of my previous apps without using EnviromentObject run fine on the canvas. I have spent hours trying to find a type-o and can't figure it out. any suggestions?

    • @kennethcoker4663
      @kennethcoker4663 8 หลายเดือนก่อน

      Fixed as well, on mine I had to add the enviromentObject modifier to the previews of my views

  • @phat80
    @phat80 4 หลายเดือนก่อน

    Sorry, in my country $40 is 1/4 of the monthly income 😂 Not a coffee budget.

  • @WeLoveYouFREEZbY
    @WeLoveYouFREEZbY 3 หลายเดือนก่อน

    but 1 viewModel for 1 view ..