A SwiftUI tip everyone needs to know: Automatic Grammar Agreement

แชร์
ฝัง

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

  • @joevero4568
    @joevero4568 ปีที่แล้ว +144

    I was expected to be underwhelmed but HOLY THAT'S AMAZING

    • @alexandersereno
      @alexandersereno 9 หลายเดือนก่อน +3

      Commenting so those asking can see easily - supported languages are English, Spanish, Portuguese, French, Italian, and German

  • @jconstant
    @jconstant ปีที่แล้ว +39

    Mind officially blown! I’d love more of these!

  • @TheOnlyTripo
    @TheOnlyTripo ปีที่แล้ว +31

    This is so great!
    How were we supposed to know about this one if it wasn’t for you? Thank you!

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

      Exactly, so many golden nuggets sprinkled absolutely everywhere all over the place 😮

  • @joee8227
    @joee8227 ปีที่แล้ว +19

    I hope this video gets liked by a lot of person.

    • @ericnail1
      @ericnail1 23 วันที่ผ่านมา

      I see what you did there 😆

  • @nigelhamilton6359
    @nigelhamilton6359 ปีที่แล้ว +9

    That was so good. Please keep doing this 😀

  • @TsiriniainaRakotonirina
    @TsiriniainaRakotonirina ปีที่แล้ว +2

    Paul, Paul, where has this been long long time ago!??? This is purely amazing 😃🤩🙌

  • @NitpickersAnonymous
    @NitpickersAnonymous วันที่ผ่านมา

    I AM actually mind blown!!

  • @TheiTE
    @TheiTE ปีที่แล้ว +5

    OH MY GOD LOL, this is AMAZING.
    This means... I have been writing long functions to do this for no reason all this time... T-T

  • @Pseudonaym
    @Pseudonaym ปีที่แล้ว +1

    Damn all these days I've been comparing values! Amazing tip!

  • @juliansha2590
    @juliansha2590 10 หลายเดือนก่อน +3

    And I’ve been using ternary operators lol . Good to know!

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

      It's basically doing the same thing, only behind the scenes ...
      The localization process is still one of the biggest pains ...

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

    Thanks! I had this problem recently and I’m surprised that the solution is this simple.

  • @nonyabidness5784
    @nonyabidness5784 ปีที่แล้ว

    Oh man I love this. Saves having to manually code it.

  • @ninelostsouls
    @ninelostsouls ปีที่แล้ว

    Incredible.
    You should definitely do more of these. !!

  • @jcut
    @jcut ปีที่แล้ว +1

    Very cool tip!

  • @flora6465
    @flora6465 ปีที่แล้ว

    Super cool tip! Definitely need more of these👍

  • @vrplayz4601
    @vrplayz4601 ปีที่แล้ว

    Awesome work! Paul as always

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

    Amazing!

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

    Best swift teacher!!

  • @richardalbury
    @richardalbury ปีที่แล้ว +1

    Mind blown: wow, thanks!

  • @haineux
    @haineux ปีที่แล้ว

    A little mysterious but very cool! Do more!

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

    So cool, gotta try this out for your example of country flags game.

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

    Thanks.

  • @Johnged15
    @Johnged15 ปีที่แล้ว

    This is a nice piece of code.

  • @JakeLovesSteak
    @JakeLovesSteak ปีที่แล้ว

    I had no idea that was possible!

  • @user-ic2tx9sb1m
    @user-ic2tx9sb1m ปีที่แล้ว

    Thank you so much❤

  • @yariva2
    @yariva2 ปีที่แล้ว

    Wow, thanks! Please keep doing shorts!

  • @joenaveau
    @joenaveau ปีที่แล้ว

    This is awesome! 🤯

  • @jim.haungs
    @jim.haungs ปีที่แล้ว

    Rails has been doing inflection for over a decade.

  • @user-ib4wj9nf2c
    @user-ib4wj9nf2c 10 หลายเดือนก่อน

    Super Cool

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

    Ohh that's really beautiful

  • @jessielinden2961
    @jessielinden2961 ปีที่แล้ว +2

    @twostraws thank you so much for this! In my use case, I sometimes use fractions, so I've been using a string, which I've found doesn't work with this approach. Any advice for leveraging this for my case?

  • @patgarner
    @patgarner ปีที่แล้ว

    Super cool!

  • @carlosswiftdev2703
    @carlosswiftdev2703 ปีที่แล้ว

    You weren't wrong 🤯 amazing! Paul is this a new feature of has it been around a while?

  • @devayz9305
    @devayz9305 ปีที่แล้ว

    AGA.. interesting. thank you

  • @seccat
    @seccat 8 หลายเดือนก่อน +1

    What 6 Languages are supported?

  • @GregT-gf9ny
    @GregT-gf9ny ปีที่แล้ว +2

    Wow! How did you find this?

  • @vasilbaramidze4185
    @vasilbaramidze4185 ปีที่แล้ว

    Nice!

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

    woah this is cool

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

    HOLY MOLY GUACAMOLE

  • @ralfboernemeier9724
    @ralfboernemeier9724 ปีที่แล้ว

    Cool … never heard about it 😮

  • @pawekoaczynski4505
    @pawekoaczynski4505 ปีที่แล้ว

    That is very nice

  • @user-rs3pf3bt7m
    @user-rs3pf3bt7m ปีที่แล้ว

    Amazing🎉🎉

  • @mathesonstep
    @mathesonstep ปีที่แล้ว

    That is amazing

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

    Accurate. 🤯

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

    What is inflex?im just beginning with swift.. thanks for your help

  • @Deadpool25mm
    @Deadpool25mm ปีที่แล้ว

    Cool!

  • @joenaveau
    @joenaveau ปีที่แล้ว +2

    Quick question - what’s up with this syntax? What does inflect mean? It seems kind of random. 😅

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

      Think it’s short for “inflection” which means: “a change in the form of a word (typically the ending) to express a grammatical function or attribute such as tense, mood, person, number, case, and gender.”

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

    💪🏼🙌🏼💪🏼

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

    I have so many questions about how does it actually work.

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

    can someone help me please ..
    i have a SWIFTUI application with a flow as follows: A(landscape orientation)->B(landscape)-C(portrait)->D(portrait). also when I navigate back from C to B it should turn back to landscape as B is in landscape. (I am using NavigationLink in my application to navigate)How do I achieve the portrait lock in swiftUI.
    i tried the .onAppear{} and .onDisappear{} method.. (firstly it is no longer available on ios 16 and secondly it gives a choppy animation where the view does not expand fully to take the new rotated screen size; there is white space after it rotates)

  • @AlanW
    @AlanW ปีที่แล้ว +2

    This is cool, but the short format is awful, you can't scrub the video if you want to go forward or back.

  • @casperes0912
    @casperes0912 ปีที่แล้ว +1

    Is there a compile-time checked version of this not relying on string literals in the Text constructor? Like Text("\(count) [person]").inflect(true)
    or something like that?

    • @casperes0912
      @casperes0912 ปีที่แล้ว

      @hydro1337x I mean sure, but that is a less ideal setup I think

  • @danvilela
    @danvilela 10 หลายเดือนก่อน +1

    What 6 languages? Also.. is this a runtime thing?

  • @ihwan_id
    @ihwan_id ปีที่แล้ว

    🎉🎉🎉

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

    What does it do when the count is 0?

  • @akar._.J
    @akar._.J 9 หลายเดือนก่อน

    Swift is a great programming language. However, the problem is that it is less popular in Asia and third-world countries.

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

    What if you support other languages? How does it handle fallback?

  • @tdrg_
    @tdrg_ ปีที่แล้ว

    Does it work with iOS 15?

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

    😮

  • @Deadlineru
    @Deadlineru ปีที่แล้ว

    Really non-obvious feature...)) And which languages are supported? I consider, English only, or some bunch of Eu languages. But that's cool, maybe, it will be more convenient to use in future releases)

  • @rondamon4408
    @rondamon4408 10 หลายเดือนก่อน +1

    I'm flipping

  • @chriswaco
    @chriswaco ปีที่แล้ว +1

    This does not seem to work. Do I have to put the singular and plural versions into a localizable.strings file too?

    • @ColeDano
      @ColeDano ปีที่แล้ว

      Same for me. Changing the String type to LocalizedStringKey fixes it however.

    • @chriswaco
      @chriswaco ปีที่แล้ว +1

      @@ColeDano Bingo. Thank you.

  • @30guarino
    @30guarino ปีที่แล้ว

    so I'm the only one that can't get that 'carrot sign' by tapping 'shift' + 'control'?

    • @AlexCrocker
      @AlexCrocker ปีที่แล้ว

      It's the carot sign above the number 6 key, not the one above control

    • @30guarino
      @30guarino ปีที่แล้ว

      @@AlexCrocker thank you lol

  • @plskz
    @plskz ปีที่แล้ว

    whaaat

  • @alan.otoole
    @alan.otoole 10 หลายเดือนก่อน

    Woah what

  • @androidfanatic6528
    @androidfanatic6528 ปีที่แล้ว

    Still needs work at 0

  • @xingzhexin8843
    @xingzhexin8843 ปีที่แล้ว

    I'm sorry I've programmed for so long in UIKit and SwiftUI that nothing really sur...
    IM SORRY WHAT DID YOU JUST DO?

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

    Go flutter

  • @orihpt
    @orihpt ปีที่แล้ว

    bro?

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

    wtf

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

    This shouldn't be a thing in my opinion

  • @matthewdolan720
    @matthewdolan720 ปีที่แล้ว

    😮