All fields

“Conditional Rendering & Lists (Keys)” in Information Technology

15 questions across 2 technologies.

Information Technology

15 questions in 2 technologies

#QuestionTechnologyTopicLevel
1How do you conditionally render one of several possible components cleanly, without a long chain of if statements? React › Conditional Rendering & Lists (Keys)ReactConditional Rendering & Lists (Keys)Advanced
2How do you show different content in React depending on a condition? React › Conditional Rendering & Lists (Keys)ReactConditional Rendering & Lists (Keys)Beginner
3How do you render a list of items in React using the map function? React › Conditional Rendering & Lists (Keys)ReactConditional Rendering & Lists (Keys)Beginner
4Why is using an array's index as a key generally considered a bad practice? React › Conditional Rendering & Lists (Keys)ReactConditional Rendering & Lists (Keys)Intermediate
5How do you render a fallback message when a list is empty? React › Conditional Rendering & Lists (Keys)ReactConditional Rendering & Lists (Keys)Intermediate
6How would you use a keyed Fragment when rendering a list of grouped elements? React › Portals & FragmentsReactPortals & FragmentsIntermediate
7How would you conditionally apply different CSS classes based on a component's state, such as showing an active style? React › Styling in React (CSS Modules, Styled Components & Tailwind)ReactStyling in React (CSS Modules, Styled Components & Tailwind)Advanced
8What is a simple real world example of when useMemo actually helps a React app? React › Performance (memo/useMemo)ReactPerformance (memo/useMemo)Beginner
9What is a Fragment in React and why would you use one instead of a div? React › Portals & FragmentsReactPortals & FragmentsBeginner
10How does the new at for control flow block work, and why does it require a track expression? Angular › New Control Flow Syntax (@if, @for & @switch)AngularNew Control Flow Syntax (@if, @for & @switch)Beginner
11How would you animate a list where items can be added or removed, such as a shopping cart? React › Animation in React (Framer Motion & React Spring)ReactAnimation in React (Framer Motion & React Spring)Intermediate
12How do you embed a JavaScript expression inside JSX? React › Components & JSXReactComponents & JSXIntermediate
13What is reconciliation in React, and how does it decide what actually needs to change on the screen? React › Virtual DOM & ReconciliationReactVirtual DOM & ReconciliationIntermediate
14How does React's reconciliation process handle components of a completely different type appearing in the same position? React › Virtual DOM & ReconciliationReactVirtual DOM & ReconciliationIntermediate
15Why does changing an element's key prop cause React to completely remove and recreate that element instead of just updating it? React › Virtual DOM & ReconciliationReactVirtual DOM & ReconciliationAdvanced