Member-only story

New SwiftUI : Instagram Profile UI

AnthonyDesignCode
3 min readAug 9, 2022

--

Photo by Merakist on Unsplash

Hello everyone, welcome to a new SwiftUI tutorial. I hope you are all doing well? Today I am going to show you how to use Environment Protocol & LazyVGrid in SwiftUI 4 and Xcode 14.

Let’s get started with opening up Xcode 14. We are going to start by adding in the assets for this project. All Assets are available in the code file at the bottom or use your own. 👍 Let’s open a new SwiftUI file called ImageView. Here we are going to show our images and set a width and height.

ImageView

We are going to create a new SwiftUI file called TabBarButton. This is going to be where we create the tabview in Instagram where you select posts, reels and tagged.

TabBarButton

Awesome now we are done with the setup we can head over to the ContentView to start coding the main ui.

What is an Environment property wrapper?

The Environment property wrapper to read a value stored in a view’s environment. Indicate the value to read using an EnvironmentValues key path in…

--

--

AnthonyDesignCode
AnthonyDesignCode

Written by AnthonyDesignCode

Hey 👋 I’m Anthony! I hope you are well?! Thank you for looking at my blog. Here you will learn how to make apps in SwiftUI for iOS 16! Thanks for reading.

No responses yet