Become A Certified React Developer: Practice Tests 1
Google Ads:
What are the two ways to handle data in React?
State & Props is the correct answer.
Which of the following command is used to install create-react-app?
npm install -g create-react-app is the correct answer. The "npm install -g create-react-app" command is used to install the create-react-app.
Which of the following acts as the input of a class-based component?
Props is the correct answer
How many ways of defining your variables in ES6?
3 is the correct option. In ES6, there are three ways of defining your variables: var, let, and const.
Advertisement
React.js create a VIRTUAL DOM in the memory.
TRUE is the correct option as React.js creates a VIRTUAL DOM in the memory.
In which of the following directory React.js components are saved?
Inside the js/components/ is the correct option. The React.js components are saved in "Inside the js/components/."
What is the declarative way to render a dynamic list of components based on values in an array?
Using the Array.map() method is the correct option. The Array.map() method is used to render a dynamic list of components based on values in an array.
Which of the following are the advantages of React.js?
All of the themis the correct option as all of the above statements are the advantages of React.js.
Advertisement
Which of the following is not a disadvantage of React.js?
The JSX in React.js makes code easy to read and write is the correct answer. "The JSX in React.js makes code easy to read and write" is an advantage of React.js.
What is the use of "webpack" command in React.js?
It is a module bundler is the correct answer. The "webpack" command is a module bundler.
What would be the output of the following example?
var Helloword=(props)=>
{
return(
Hello World 1
Hello World 2
);
}
ReactDOM.render(,mountNode)
Error is the correct option. The two adjacent elements in JSX should be wrapped in an element so, this program will result an error.
Which of the following is a must API for every React.js component?
render Component is the correct option. The render Component is a must API for every React.js component.
Advertisement
What of the following is used in React.js to increase performance?
Virtual DOM is the correct answer. Virtual DOM is used in React.js to increase performance.
Which of the following is the correct name of React.js?
All of the them is the correct option. React.js is a free, open-source front-end JavaScript library used for building user interfaces or UI components. It is also known as React or ReactJS.
What is a state in React?
Internal storage of the component is the correct answer.
Which of the following option is correct in the case of the Babel?
Both of them is the correct option as both of the above statements are correct.
Advertisement
Which of the following keyword is used to create a class inheritance?
Extends is the correct answer. The "Extends" keyword is used to create a class inheritance.
A class is a type of function, but instead of using the keyword function to initiate it, which keyword do we use?
Class is the correct answer. A class is a type of function, but instead of using the keyword function to initiate it, we use the keyword class.
How many numbers of elements a valid react component can return?
1 is the correct answer. In react component, we can return only one element.
What is the default port where webpack - server runs?
8080 is the correct answer. The default port for webpack - server is 8080.
Click Next Button or HERE for more Questions