React Quiz

React Quiz

Professional Development

40 Qs

quiz-placeholder

Similar activities

GEN61-129 Vocabulary Set 5A

GEN61-129 Vocabulary Set 5A

University - Professional Development

38 Qs

STRUCTURE TOEFL

STRUCTURE TOEFL

University - Professional Development

40 Qs

Quiz 1 EL

Quiz 1 EL

Professional Development

40 Qs

Public International Law

Public International Law

Professional Development

35 Qs

1 month Review

1 month Review

Professional Development

35 Qs

wh-questions

wh-questions

7th Grade - Professional Development

40 Qs

Linguistics Text

Linguistics Text

University - Professional Development

40 Qs

Computer Basics Quiz

Computer Basics Quiz

Professional Development

40 Qs

React Quiz

React Quiz

Assessment

Quiz

English

Professional Development

Easy

Created by

Dotnet Quiz

Used 2+ times

FREE Resource

40 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the primary purpose of `useCallback` in React?
To memoize a component
To memoize a function reference
To create a new function every render
To manage side effects

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the difference between `useEffect` and `useLayoutEffect`?
`useEffect` runs before paint, `useLayoutEffect` runs after
`useLayoutEffect` runs synchronously after DOM mutations, `useEffect` runs asynchronously after paint
They are identical
`useLayoutEffect` is deprecated

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does `React.memo` do?
Prevents re-rendering of a component
Memoizes a function
Memoizes a component and prevents re-render unless props change
Creates a new component

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of `key` prop in React lists?
To style list items
To uniquely identify elements for efficient re-rendering
To bind data
To handle events

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the difference between `Context API` and `Redux`?
Context is for global state, Redux is for local state
Redux is built-in, Context is external
Context is simpler and built-in, Redux is more powerful and suited for complex state
They are interchangeable

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of `useRef` in React?
To create a reference to a DOM element or persist a mutable value
To manage state
To trigger re-renders
To memoize a component

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the role of `React.StrictMode`?
To enable production optimizations
To highlight potential problems in an application
To disable warnings
To enforce strict typing

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?