How to get a view size in SwiftUI

  Рет қаралды 1,544

Mike Mikina

Mike Mikina

Күн бұрын

Пікірлер: 10
@SørenGregersen-e8e
@SørenGregersen-e8e Жыл бұрын
Super useful! Thanks for sharing the tip. I think I'm going to copy your extension and then perhaps use a @Binding instead of having the closure.
@markaurelius61
@markaurelius61 Жыл бұрын
Very neatly done. I like the way you tidied it up in that modifier
@mikemikina
@mikemikina Жыл бұрын
Thanks Mark!
@vitorgomes4794
@vitorgomes4794 9 ай бұрын
First of all, thanks for sharing this content @Mike. Second, I did the same thing on my project, but there I am using a List, not a ScrollView, and my button actually are two buttons inside a VStack. I am using a GeometryReader on this two buttons VStack but when I add the variable to the List .padding modifier my buttons VStack creates a weird white stripe behind, starting in the middle of the buttons VStack and going to the bottom. Have you got this behavior?
@mikemikina
@mikemikina 9 ай бұрын
Not sure if I got this 🤔 Could you share a sample code?
@vitorgomes4794
@vitorgomes4794 9 ай бұрын
@@mikemikina Yes! How can share with you?
@mikemikina
@mikemikina 9 ай бұрын
You can create a Gist on GitHub or a regular repo. If you don't want to make it public, you can just add me to this repo. My GitHub handle is: "mikina."
@vitorgomes4794
@vitorgomes4794 9 ай бұрын
@@mikemikina It is the file pinned on my home page of GitHub. Sao Judas Tadeu Americana/Views/PrayersViews/NovenaView.swift, that's the file
@obrienserhii
@obrienserhii 5 ай бұрын
thanks!!!
@victorriurean
@victorriurean 7 ай бұрын
🔥
How to use @ViewBuilder in SwiftUI | Advanced Learning #9
24:01
Swiftful Thinking
Рет қаралды 27 М.
coco在求救? #小丑 #天使 #shorts
00:29
好人小丑
Рет қаралды 45 МЛН
What type of pedestrian are you?😄 #tiktok #elsarca
00:28
Elsa Arca
Рет қаралды 36 МЛН
How to Get User Location on a Map - Swift
26:11
Sean Allen
Рет қаралды 65 М.
What Is SwiftUI? | In Under 10 Minutes
6:57
Matt Heaney Apps
Рет қаралды 14 М.
How to Make a Card View in SwiftUI - Step by Step for Beginners (2023)
32:02
A Swiftly Tilting Planet
Рет қаралды 11 М.
Building Grids in SwiftUI 2.0 for iOS 14
8:24
Paul Hudson
Рет қаралды 44 М.
FASTEST Way to Learn Coding and ACTUALLY Get a Job
8:50
Sahil & Sarra
Рет қаралды 7 МЛН
SwiftUI GeometryReader
27:53
Stewart Lynch
Рет қаралды 12 М.
How to create custom ViewModifiers in SwiftUI | Advanced Learning #1
18:59
SwiftUI: Environment property. You should use it!
7:43
Mike Mikina
Рет қаралды 924