How to CONDITIONAL RENDER in React ❓

  Рет қаралды 24,733

Bro Code

Bro Code

8 ай бұрын

Conditional rendering = allows you to control what gets rendered in your application based on certain conditions. (ex. show, hide, or change components)

Пікірлер: 37
@BroCodez
@BroCodez 8 ай бұрын
import UserGreeting from './UserGreeting.jsx' function App() { return( ); } export default App import PropTypes from 'prop-types'; function UserGreeting(props){ const welcomeMessage = Welcome {props.username} const loginPrompt = Please log in to continue return(props.isLoggedIn ? welcomeMessage : loginPrompt); } UserGreeting.proptypes = { isLoggedIn: PropTypes.bool, username: PropTypes.string, } UserGreeting.defaultProps = { isLoggedIn: false, username: "Guest", } export default UserGreeting .welcome-message{ font-size: 2.5em; background-color: hsl(120, 100%, 42%); color: white; padding: 10px; border-radius: 5px; margin: 0; } .login-prompt{ font-size: 2.5em; background-color: hsl(0, 100%, 42%); color: white; padding: 10px; border-radius: 5px; margin: 0; }
@imbomb
@imbomb 8 ай бұрын
Pls I beg of you don't relent so as we aren't.Just keep posting videos till this module is complete.React is a very important aspect in Frontend Development
@unknown-person-14.
@unknown-person-14. 8 ай бұрын
i beg you to make a small python episode in which you will teach how to communicate between server and client in lan using sockets and how to move a thing from buttons using server so connected clients would see the change
@anesmessahli5863
@anesmessahli5863 8 ай бұрын
Yo pls can u suggest to me wich video i should watch to learn html and css .. you have a 1hour video of html and 1hour video of css also you have a 4hour video such as a combination between the last twos.. so what should i watch ?
@indology7975
@indology7975 8 ай бұрын
bro please make mastery level detail. detail to detail python full couse , make a course that by doing that one can become Albert Einstain of coding.
@senisia
@senisia 8 ай бұрын
i love your new react series. I just started learning it and you came out of nowhere
@aungaungab1967
@aungaungab1967 8 ай бұрын
Please make a full react series course 🙏🙏🙏🙏🙏
@g.ryanpeterson9686
@g.ryanpeterson9686 7 ай бұрын
Just started learning React and your videos are very easy to follow and learn from. Thank you!!
@shivanshuhere
@shivanshuhere 6 ай бұрын
simple and clear explanation :) loved it
@TahaZolfi
@TahaZolfi 8 ай бұрын
bro code teaches you so good that u feel its so easy
@Legacylanes_moto
@Legacylanes_moto 6 ай бұрын
great series bro.. byte sized tutorials makes life easier. Thanks.. waiting for more.
@NazneenNaharNishi
@NazneenNaharNishi 8 ай бұрын
Bro make a complete tutorial for android development.....Your courses are completely educative.❤❤❤❤❤
@houdariyad4889
@houdariyad4889 8 ай бұрын
can't thank u enough bro
@AIZEN155
@AIZEN155 8 ай бұрын
Even though I know React, I enjoy watching your videos
@name_yug
@name_yug 8 ай бұрын
Pls make a full course on react and typescript
@ngehbrandon9491
@ngehbrandon9491 8 ай бұрын
Thanks for the video bro
@d1ce966
@d1ce966 8 ай бұрын
Bro post more react i love it
@elawet435
@elawet435 8 ай бұрын
Thank u so much my Bro
@1T_pressly
@1T_pressly 8 ай бұрын
Thank you bro for the code
@Yesterday_i_ate_rat
@Yesterday_i_ate_rat 8 ай бұрын
Thank you so much sir ❤❤
@andromilk2634
@andromilk2634 4 ай бұрын
Since you were using Javascript variables, wouldn't you need to use {} on here as well like you usually do? Or are those not necessary in conditionals? Thanks!
@user-et6cq4cj5s
@user-et6cq4cj5s 8 ай бұрын
do you plan to make advance c# course ?
@hunin27
@hunin27 8 ай бұрын
thanks! ❤
@unknown-person-14.
@unknown-person-14. 8 ай бұрын
i beg you to make a small python episode in which you will teach how to communicate between server and client in lan using sockets and how to move a thing from buttons using server so connected clients would see the change
@pintertenan8057
@pintertenan8057 8 ай бұрын
Greeting from a bro!
@Ceszilla
@Ceszilla 8 ай бұрын
Can you please explain how to upload images to a react project?
@lokrajpyakurel2563
@lokrajpyakurel2563 7 ай бұрын
Waiting for new video on React from Bro Code 😊
@Delicatamente
@Delicatamente 2 ай бұрын
huge thanks!
@bladebeats7375
@bladebeats7375 8 ай бұрын
please make a video on how to automate ur work using python
@graiselin2791
@graiselin2791 8 ай бұрын
Love you 😘😘
@manojmurugan590
@manojmurugan590 8 ай бұрын
Bro please upload full video How to contact you for courses for paid
@Ken-zh4gu
@Ken-zh4gu 3 ай бұрын
Please do full django course python web development framework if you can
@indology7975
@indology7975 8 ай бұрын
bro please make mastery level detail. detail to detail python full couse , make a course that by doing that one can become Albert Einstain of coding.
@vishnuk6417
@vishnuk6417 8 ай бұрын
Hii.....! it's 13th comment 😍😍
@Gunz1234
@Gunz1234 8 ай бұрын
Bro Code ❤
@Yakuzanis
@Yakuzanis 8 ай бұрын
Bro Code = Chad Code
@kaungkinzone2448
@kaungkinzone2448 8 ай бұрын
random comment 4.0
How to render LISTS in React 📃
26:40
Bro Code
Рет қаралды 23 М.
PROPS in React explained 📧
12:09
Bro Code
Рет қаралды 61 М.
🌊Насколько Глубокий Океан ? #shorts
00:42
бесит старшая сестра!? #роблокс #анимация #мем
00:58
КРУТОЙ ПАПА на
Рет қаралды 2,7 МЛН
WHO DO I LOVE MOST?
00:22
dednahype
Рет қаралды 21 МЛН
Why You Should Always Help Others ❤️
00:40
Alan Chikin Chow
Рет қаралды 134 МЛН
Turning bad React code into senior React code
13:10
Cosden Solutions
Рет қаралды 86 М.
Why Signals Are Better Than React Hooks
16:30
Web Dev Simplified
Рет қаралды 456 М.
How To Create Decorator Functions In Python
4:59
Taylor's Software Solutions
Рет қаралды 3 М.
All The JavaScript You Need To Know For React
28:00
PedroTech
Рет қаралды 563 М.
Things you didn't know about re-rendering in React
4:40
Code Sketched
Рет қаралды 24 М.
All useEffect Mistakes Every Junior React Developer Makes
22:23
10 React Antipatterns to Avoid - Code This, Not That!
8:55
Fireship
Рет қаралды 718 М.
React js how to add CSS styles 🎨
8:16
Bro Code
Рет қаралды 20 М.
Every React Concept Explained in 12 Minutes
11:53
Code Bootcamp
Рет қаралды 415 М.
🌊Насколько Глубокий Океан ? #shorts
00:42