Vue Slots Simplified

Поділитися
Вставка
  • Опубліковано 17 жов 2024

КОМЕНТАРІ • 66

  • @LesCarbonaro
    @LesCarbonaro 3 роки тому +27

    Excellent, well-rounded intro to a topic that always gives me grief. I like how you started your explanation from first principles and then built up to intermediate and advanced use of slots. Very smoothly executed! Thank you.

    • @LearnVue
      @LearnVue  3 роки тому +4

      Glad to hear! Slots used to be difficult for me too, but they're such a cool feature of Vue once it finally clicks.

  • @TuTrinh211
    @TuTrinh211 3 роки тому +10

    Great explanation. Slots and scoped slots are hard to explain but you did it with ease.

  • @markg5986
    @markg5986 3 роки тому +3

    This is the best explanation I've seen about vue slots. Thank you!

  • @jntaca
    @jntaca 3 роки тому +10

    Thanks ! !
    Very clear explanation of a pattern-breaking functionality.
    Your channel is excelent, you'll have a lot of subscribers in a short time.

  • @gmielli1281
    @gmielli1281 3 роки тому +6

    WHAT A GEM 💎! Outstanding content, dude! Keep up the great work

  • @mubafaw
    @mubafaw 2 роки тому +5

    Lets just say you're a legend! 😊 Thanks for putting me out of my mysery with Vue Slots! 😊

  • @nevinkuser9892
    @nevinkuser9892 Рік тому

    Great work. I sent an image tag back to my component! Very exciting. For anyone trying to do this, make sure to add an id to whatever your passing in. It's the only way to style it.
    For example,
    #pic {
    width: 40vw;
    height: auto;
    }

  • @cauesomenzi
    @cauesomenzi 3 роки тому +7

    Really clear explanation. Thank you so much!

    • @LearnVue
      @LearnVue  3 роки тому

      glad it was helpful!

  • @nswk_
    @nswk_ 2 роки тому +2

    I can't believe this is the video where scoped slots finally clicked for me! Thank you so much! #subscribed

  • @tomtomnichtnavi1431
    @tomtomnichtnavi1431 2 роки тому

    4:35 very interesting to see that you can use the same slot multiple time. It makes total sence, but it wasn't apperant to me at first. Great video, slots have been a bit of a mistery to me, thanks.

  • @dylanwarrener5857
    @dylanwarrener5857 2 роки тому +1

    Great video. Straight to the point and simple to follow. Also bonus for not sounding like a robot 😅

  • @JoschaWeiss
    @JoschaWeiss Рік тому

    thanks! was looking for scoped slots (without knowing the term) and found it!

  • @kirankothandan5529
    @kirankothandan5529 Рік тому

    This is one of the finest and simple explanation ❤❤

  • @ThaRealIansanity
    @ThaRealIansanity Рік тому +1

    One thing confuses me. Why would I want to define data in the child, access it in the parent, and then pass it back into the child via the slot? I'm googling but not finding any examples where it doesn't make more sense to just keep the data in the parent and pass it to the child. I guess if the child makes an API call or something that changes the data and I want my parent component to modify the data based on some condition of what it received from the child before passing it back in? Just trying to make sense of it.

    • @AnisD756
      @AnisD756 Рік тому

      Let's say conditional rendering for example, or passing values to multiples component..Or side effect in the parent component :

  • @sven_527
    @sven_527 Рік тому +1

    When you do videos like this, it would be cool if you linked the code you showed so you could check it out yourself. You could display the code like that, or maybe there's a way to open someone elses Vue playground, but I would generally appreciate being able to look through it at your own pace.

  • @khoaphan9130
    @khoaphan9130 2 роки тому +1

    Thanks very much, a straightforward and clear tutorial!

  • @2009massi
    @2009massi 2 роки тому

    Thankx for breaking it down.. great tutorial for beginners

  • @jamols09
    @jamols09 3 роки тому +1

    Hello there, I wanted to make a global component (not sure if this is right term). Similar to like a dialogbox, notification or simple modal.
    Scenario: I have a modal for registration. Message: "A message is sent to your email for verification". Button: "Re-send email"
    With `Message` part its easy since I can just pass the data however I am more concerned with the `Button's` functionality the for resending email. Is this gonna work with slot or prop ?

    • @LearnVue
      @LearnVue  3 роки тому

      if you're making a separate component, you can have the button functionality inside that global modal component and handle resending the email there!

  • @watevakid
    @watevakid Рік тому

    The component "CaptionedContent" is capitalized, but in the template you use "captioned-content" - is this vue syntax? do you have a video about that? I'm sure its basic, but I'm just starting to look at vue and few videos. really like your teaching style/videos. thanks man!

    • @LearnVue
      @LearnVue  Рік тому

      yup! it's a common Vue practice to use kebab-case in the templates.

  • @devdevil3087
    @devdevil3087 2 роки тому

    We use slots for template code and if we don't allow template code we use properties?

  • @binoysarker903
    @binoysarker903 3 роки тому

    hello, my problem is that when i refresh the page the slot content data inside the loop is not rendering.

  • @deniznehlyadyuk4447
    @deniznehlyadyuk4447 2 роки тому

    This tutorial saved my time thanks.

    • @LearnVue
      @LearnVue  2 роки тому

      you’re welcome😅

  • @tomzhao8262
    @tomzhao8262 3 роки тому +2

    Brief and effecient!

    • @LearnVue
      @LearnVue  3 роки тому

      thank you so much!

  • @MatthewHinton
    @MatthewHinton 3 роки тому +1

    Really nice explanation.

  • @bodiasokoliuk
    @bodiasokoliuk 3 місяці тому

    thank you so much for explanation, wow

  • @mezianibelkacem650
    @mezianibelkacem650 Рік тому

    Very good explantation like it :D

  • @slimyelow
    @slimyelow 2 роки тому

    Outstanding explanation. Bravo!

  • @OswaldChisala
    @OswaldChisala Місяць тому

    You're an absolute Chad, bro! thank you! 🤩

  • @saturne2248
    @saturne2248 2 роки тому +1

    Very interesting and helpful video thanks a lot

  • @electroacoustico1384
    @electroacoustico1384 2 роки тому

    I see a PH flag 🇵🇭 in the background bro, I like! lol GREAT CONTENTS!!

  • @другМаша
    @другМаша 2 роки тому

    what a great explanation!

  • @allaghi
    @allaghi 3 роки тому

    Thank you so much for your making this video.

    • @LearnVue
      @LearnVue  3 роки тому

      It's my pleasure 🗣

  •  2 роки тому

    you are the best 🙌🔥

  • @standroads
    @standroads 2 роки тому

    Oh brother I really long time tried to understand scoped-slots and only you could give me right understanding...

  • @AnyFactor
    @AnyFactor 3 роки тому +1

    Great content!

  • @thewiscokid81
    @thewiscokid81 3 роки тому

    Keep up the good work 😸

  • @_q1b_
    @_q1b_ 3 роки тому +1

    Hey I am enjoying your videos can you make one video on provide and inject
    Please.

    • @LearnVue
      @LearnVue  3 роки тому

      definitely! great suggestion

  • @shlomiyahbes4882
    @shlomiyahbes4882 Рік тому

    Thanks!

  • @hamzaessaadi7569
    @hamzaessaadi7569 2 роки тому

    thank youuu

  • @sharonlau3963
    @sharonlau3963 2 роки тому

    Thx!

  • @anantawijaya1594
    @anantawijaya1594 Рік тому

    great

  • @sopheakphat1634
    @sopheakphat1634 2 роки тому

    🥰👍

  • @jacky8595125
    @jacky8595125 2 роки тому

    thks

  • @AstroSardaukar
    @AstroSardaukar 2 роки тому

    Your picture returns a 404 error.
    Thanks for the tutorial.

  • @nested9301
    @nested9301 Рік тому

    vue needs to stop with this new features i'm confusing so much to learn bro