Create a modal with React (Pop-up)

แชร์
ฝัง

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

  • @TJA91910
    @TJA91910 ปีที่แล้ว +11

    I've referenced this video countless times for a variety of projects. Thank you for taking the time to put this together, you are a true hero!

  • @streetrat7050
    @streetrat7050 3 ปีที่แล้ว +13

    Thank you so much for your contribution. I have spent far too long now trying to find an example that is simple, direct and to the point.

  • @jameslovell5201
    @jameslovell5201 3 ปีที่แล้ว +30

    Quick! Clear! Concise! An excellent tutorial, my friend!

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

    I dont usually comment on yt tutorials, but this is the only modal video I felt useful. Thankyou!

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

    really, i'm so happy to hear you again, i usually cach your french tutorials, this modal is all i wanted 🙏👌👌

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

    Very very great video. You simplified this down to clean concise code that was very easy to follow. The css styling being done ahead of time helps a lot aswell because this video was how to make it work not how to make it pretty so thanks for getting that done outside the actual content!
    10/10

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

    This is exactly what I was looking for. Keep the good work going mate!

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

    Beautifully done... Using basic concepts, in a Clear and concise way bro

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

    Best modal video on youtube (or at least out of like 10 that I compared it with).

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

    I was looking something like this to insert into my project, Merci infiniment monsieur pour cette contribution. Vous etes magnifique!

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

    Thank you, you explained it so simply! Also, your accent is very cool :D

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

      Glad it helps !
      The French accent never leaves ✌️

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

    Straight to the point. Perfect! You just got a follower.

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

    I have been referencing to this video many times, thanks man

  • @kamichikora6035
    @kamichikora6035 2 ปีที่แล้ว

    As always, great work. Straight to the point

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

    Very easy tutorial, thanks for the source code!

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

    Great quick & clear explanation! Thanks!

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

    You are superb!!! easily discuss and understandable code. Thank you so much.

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

    Thanks for this video, really nice and simple explanation

    • @TheWebSchool
      @TheWebSchool  3 ปีที่แล้ว

      Glad it helps, and nice pic in front of the Hungarian Parliament mate ✔️

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

    Dude, this is so nice

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

    Thanks, just what I was looking for ! Very Helpful.

  • @Greenlight123
    @Greenlight123 3 ปีที่แล้ว

    Thanks. That is exactly what i was looking for. A Point of Reference

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

    short & clear ! thank u so much for that

  • @ABC-el3ql
    @ABC-el3ql 3 ปีที่แล้ว

    WOW!! Thank you so much from S.Korea!!

  • @fancybeing1296
    @fancybeing1296 2 ปีที่แล้ว

    iam always scared to code an overlay but this video literally helped me in 5 mins

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

    It is very helpful video for building Modal using Vanilla CSS. Thanks.

  • @User-nn9uw
    @User-nn9uw 2 ปีที่แล้ว

    So simply, thank you dude

  • @AdarshYadav-cf9be
    @AdarshYadav-cf9be 5 หลายเดือนก่อน

    Thankyou so much brother i was suffering from so many problems thankyou so much...😢

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

    An excellent tutorial! Thank you so much.

  • @mohammedhassan-xc7nh
    @mohammedhassan-xc7nh ปีที่แล้ว

    so short and so clear Im Arabian but I understood so much thx bro

  • @diamondsky6605
    @diamondsky6605 2 ปีที่แล้ว

    Wow même en anglais j'ai reconnu ta voix direct 😂 Je savais pas que tu avais une autre chaine

  • @azashik5678
    @azashik5678 3 ปีที่แล้ว

    Nice Tutorial Sir . Quick And clear

  • @souravdutta5703
    @souravdutta5703 3 ปีที่แล้ว

    wow!! you made creating modal so simple!!

  • @BBoyXy
    @BBoyXy 3 ปีที่แล้ว

    Thank you, keep up the good work

  • @polestudiosaroundtheworld
    @polestudiosaroundtheworld 3 ปีที่แล้ว

    Thank you, the tutorial is really clear! Just what I need.

  • @samriddhabajpai1846
    @samriddhabajpai1846 2 ปีที่แล้ว

    Thank you for the easiest explanation!!

  • @ziyaulrana1840
    @ziyaulrana1840 3 ปีที่แล้ว

    Very simple and easy method
    Thanks for motivation

  • @iafofkhadze4628
    @iafofkhadze4628 2 ปีที่แล้ว

    wow u made this super easy tho

  • @chiomaubaezuonu3875
    @chiomaubaezuonu3875 2 ปีที่แล้ว

    You're amazing

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

    Thank
    You It's working!

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

    Thanks bro it was really useful 👍👍👍

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

    Excellent!! :)
    But 2 things :
    1 ) Why bother with State when you can just pass an "active-modal" class to body and handle everything with CSS?
    2) Studies shows that a lot of people would click on the previous button of their browser when modal shows up. So we should prevent that maybe with a new page direction.
    Thoughts?

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

    Excellent Example

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

    Super helpful thanks!

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

    Very good tutorial, thank you ^^

  • @younesmansourbokhtache118
    @younesmansourbokhtache118 2 ปีที่แล้ว

    Thank you so much, the tutorial is really clear

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

    Great tutorial!

  • @Jonsy
    @Jonsy 2 ปีที่แล้ว

    This is great!! thank you so much

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

    Excellent one. Thanks.

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

    Nice tutorial man!

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

    Great, quick tutorial for building modals however doesn't address event propagation. I build a form inside a modal and on click it closes the form.

  • @0xBK201
    @0xBK201 2 ปีที่แล้ว

    Thanks for this.

  • @ritchieways9495
    @ritchieways9495 2 ปีที่แล้ว

    Thanks so much. You saved me

  • @kamamedia3535
    @kamamedia3535 3 ปีที่แล้ว

    thanks man, really nice n cool to implement

  • @DS-qz2gu
    @DS-qz2gu ปีที่แล้ว

    When I learned React, I learned that when you modify the current state to set a new state (e.g., negating a value to toggle boolean state), there’s a specific syntax to ensure that you get the current state instead of risking using a previous version of the state. Instead of this:
    setModal(!modal);
    You’d use this:
    setModal((prevModal) => !prevModal);
    Is this true? Is it just not important in this use case?

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

    Really helpful...! Thank you

  • @ashadulmridha4265
    @ashadulmridha4265 3 ปีที่แล้ว

    Wow man it's very Cool

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

    gracias perritoo sos crkack

  • @nicudomenti5235
    @nicudomenti5235 2 ปีที่แล้ว

    Nice video, thank you!

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

    thank you my friend

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

    good tutorial, but how can You animate this modal? Especially closing modal?

  • @worldclasscode1847
    @worldclasscode1847 2 ปีที่แล้ว

    Great video ! :)

  • @EvGen-e2d
    @EvGen-e2d ปีที่แล้ว

    Ok the problem is what if my modal bigger height then viewport?
    overflow-y: scroll; doesn't help because it has different scroll and scrolls much slower
    then body scroll.

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

    it's really cool

  • @ambitionhut
    @ambitionhut 2 ปีที่แล้ว

    This doesent work sadly on my end. The idea of creating both the button and modal in the same component only works if its like you example. But what if the button is on the navbar? when I do it, the modal pops up inside the navbar..

    • @TheWebSchool
      @TheWebSchool  2 ปีที่แล้ว

      Hey, yeah it was for the purpose of the video.
      Most of the time we use the context API or redux or whatever state manager to handle the triggering of a modal.

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

    Thankyou for your help

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

    Help, i have the exact same code and modal is not showing :s

    • @TheWebSchool
      @TheWebSchool  3 ปีที่แล้ว

      Source code is in the description my friend

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

    I have a target value to display but when i click submit the value no longer display. What can i do?

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

    Any way to make it so that it fades in and out smoothly?

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

    Please how do you enable intellisense like when you did div.modal

  • @attilakovacs4364
    @attilakovacs4364 3 ปีที่แล้ว

    ty great video,one question though,how do I enable scrolling in the modal? I added overflow-y: auto or scroll but it doesnt work.

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

      nevermind I'm stupid,I added it to the modal-content section not in the '.modal' section,now it works!

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

    how can we delay the pop up message by a few milliseconds?

  • @mihaibalan1917
    @mihaibalan1917 2 ปีที่แล้ว

    This helped me a lot. How can I make the content of my modal scrollable? (I have a photo gallery in the modal)

  • @Teodorant1
    @Teodorant1 2 ปีที่แล้ว

    I downloaded the project and copied the components file and put it into my SRC file, and imported it the same way into my app.js, I couldn't get it to work. Please help!

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

    On clicking Open button, the modal is not opening. Can anyone please suggest?

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

    so which is the best method, using portals or using this approach?

  • @julien25585
    @julien25585 3 ปีที่แล้ว

    How can i fix this error:
    "./src/App.js
    Module not found: Can't resolve './Components/Modal/Modal' in 'C:\Users\user\Desktop\Test\Test\src'"
    i use this import:
    "import Modal from './Components/Modal/';"

    • @TheWebSchool
      @TheWebSchool  3 ปีที่แล้ว

      This is mainly a problem with the path, check the name of your paths

    • @julien25585
      @julien25585 3 ปีที่แล้ว

      @@TheWebSchool Maybe i dont understand bcs im kinda new to do programming. I use a relative path, it should be okay then or not?
      Actually i have no clue how to fix this :/

    • @hamidrezarahimi6651
      @hamidrezarahimi6651 3 ปีที่แล้ว

      If your folders structure is the same as what was explained in the video, you should add the Component file to your import statement as well. With that being said, you have to update your import to:
      import Modal from "./Components/Modal/Modal";

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

    how do you run that modal.js on terminal?
    be cause i use npm start but i can't start it

  • @augischadiegils.5109
    @augischadiegils.5109 2 ปีที่แล้ว

    ❤️❤️❤️❤️

  • @ralpha973
    @ralpha973 6 วันที่ผ่านมา

    Est ce que t'es français ?
    Parce que t'as vraiment un accent

  • @nischithr5428
    @nischithr5428 2 ปีที่แล้ว

    Thank You! ☺☺

  • @henzelsargsyan4302
    @henzelsargsyan4302 2 ปีที่แล้ว

    Thanks a lot!

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

    thank you so much bro bro

  • @dev_catM
    @dev_catM 3 ปีที่แล้ว

    Top!👍

  • @matiasrocca4702
    @matiasrocca4702 2 ปีที่แล้ว

    Hey!! Im having trouble with the overlay toggle on the overlay div. It is also executing the function when clicking inside the popup component (which kinda makes sense, since the component is within the overlay div). Does anybody know how may I fix this?

    • @matiasrocca4702
      @matiasrocca4702 2 ปีที่แล้ว

      Im not being able to call the function only while clicking the overlay (outside part of the box), im also calling it when clicking on the inside. This is a problem, because im trying to fill a form inside the component

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

    thank you it is what i want to know how to create a modal that is shown when i login my bank account. it contains points that turn and text please wait before showin my bank receipt

  • @TheNarstonerz
    @TheNarstonerz 2 ปีที่แล้ว

    Sweet french accent

  • @EminoMeneko
    @EminoMeneko 3 ปีที่แล้ว

    Super bien expliqué mais chez moi ça ne crée pas la modale.
    React dev tools me permet de voir que le state toggle mais rien ne s'affiche.
    En fait c'est parce que je part des templates depuis le site de Bootstrap et que le code ne marche pas tout à fait de la même manière.
    En tout cas ça a répondu à la question que je me posais.

    • @TheWebSchool
      @TheWebSchool  3 ปีที่แล้ว

      Thanks, We speak English here :)

  • @PROTECHRAHUL
    @PROTECHRAHUL 2 ปีที่แล้ว

    how can we do it on onload

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

    Thank you

  • @khan.hassan
    @khan.hassan 3 ปีที่แล้ว

    Thanks 👍

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

    0:29 and we are going to fk us

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

    Thanks .

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

    not working now :((

  • @sandeepdhungana6657
    @sandeepdhungana6657 3 ปีที่แล้ว

    Great

  • @mega.pe4enka147
    @mega.pe4enka147 3 ปีที่แล้ว

    красава

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

    why do u say 'hoviley' insted of overlay

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

    Source Code Please

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

    there are 4 big mistakes. how dare u upload a video. u are junior level

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

    what is this heavy accent. it is hard to listen . ufff so bad.

  • @sinclair1082
    @sinclair1082 2 ปีที่แล้ว

    Thank you!