REACT NATIVE QUIZ DESCRIPTION

Which of the following method refers to the parent class in React.js? 
 

  • inherits() 
     


  • self() 

     


  • super() 
     


  • this() 
     

Which of the following acts as the input of a class-based component? 

  • Class 
     


  • Factory 
     

  •  
    Render 

     


  • Props 
     

What does props stand for? 
 

  • Proper Arguments 

     


  • Properties 
     


  • Proper Return Values 
     


  • All of the above 
     

Which of the following is a correct definition of state in react? 

  • A persistent storage 
     

  • An internal data store (object) of component 
     

  •  Both 
     

  • None 

What is a state in React? 
 

  • A permanent storage. 
     


  • Internal storage of the component. 
     


  • External storage of the component. 


  • None of the above. 

React is also known as _____. 
 

  • ReactJS 
     


  • js
     


  • Both A. and B. 
     


  • None of these 

In ES6 – Which keyword is used for class inheritance? 

  • extends 
     


  • extend 
     


  • inheritance 
     


  • inheritances 

What does ReactJS use to increase performance? 

  • Virtual DOM 
     

  • Original DOM 

     

  • Local DOM 
     

  • None of the Above 
     

In ES6 – The class properties are assigned inside a _____ method. 

  • props() 
     

  • properties() 

     

  • constructor() 
     


  • react-properties() 
     

Why is the usage of setState? 
 


  • Invoke code after the setState operation is done. 

     



  • Replace the state completely instead of the default merge action. 
     


  • Access the previous state before the setState operation. 
     



  • None of the above. 
     

What will happen if you render an input element with disabled = {false}? 

  • It will be rendered as disabled 
     


  • It will not be rendered at all 
     


  • It will be rendered as enabled 


  • You cannot set it false. 

In ES6 – What is the correct syntax of class inheritance? 

  • class class1 extends class2{...} 
     


  • class class1 extends | class2{...} 

     


  • class class1 | extends class2{...} 

     


  • class class1 | extends | class2{...} 
     

What is the declarative way to render a dynamic list of components based 
on values in an array? 

 

  • Using the reduce array method 
     

  •  
    Using the <Each /> component 
     


  • Using the Array.map() method 
     


  • With a for/while loop 

In ES6 – Which keyword is used to initiate a class? 

  • function 
     

  • class 
     

  • ReactClass 
     


  • ReactClassJs 
     

ReactJS uses _____ to increase performance 
 

  • Virtual DOM 
     

  • Original DOM 
     

  • Both of above 
     

  • None of above 

Which statement is true for props? 

  •  it is set and updated by the object 
     


  •  can be modified 
     

  •  it is mutual 
     

  • can’t be modified 

In which of the following condition, the React.js Lifecycle method static 
getDerivedSateFromProps(props, state) is called? 

 

  • The component is created for the first time. 
     


  • The state of the component is updated. 
     


  • Both of the above. 
     


  • None of the above. 

For controlled components in react 

  •  Source of truth is DOM 
     

  •  Source of truth is component state 
     

  •  Source of truth can be anything 
     

  •  None of above 

For uncontrolled components in react 

  •  Source of truth is DOM 
     

  • Source of truth is component state 
     

  •  Source of truth can be anything 
     

  •  None of above 

Which ReactJS command is used to create a new application? 
 

  • create-react-app 
     


  • new-react-app 
     


  • create-new-reactapp 
     


  • react-app 

With an arrow function – this keyword represents _____. 
 

  • Content 
     

  • Header object 
     


  • Current object 
     

  • Child object 

Which of the following statement is true for uncontrolled components in 
React.js? 

  • The source of truth is DOM. 

     

  •  

    The source of truth is a component state. 

     

  •  

    The source of truth can be anything. 

     

  •  

    None of the above. 

What is the use of the create-react-app command in the React.js 
application? 


  • It is used to update a React app. 
     


  • It is used to create a new React app. 
     



  • It is used to install dependencies. 
     



  • None of the above. 

In ES6 – A class is a type of ____. 
 

  • Basic datatype 
     

  • Derived datatype 
     


  • Variable 
     


  • Function 
     

A valid react component can return ...... number of elements. 

  • 1

  • 2

  • 3

  • None of the Above 
     

Which of the following command is used to install create-react-app? 
Play Videox 

  • npm install -g create-react-app 
     


  • npm install create-react-app 
     


  • npm install -f create-react-app 
     


  • install -g create-react-app
     

Ref in react component is used to assign reference to DOM elements. Ref 
can be created by 

  •  Calling React.createRef method 
     

  • Assigning a value to ref attribute in JSX 
     

  •  Both of above 
     

  •  None of above 

Can we use React native for web? 
 

  •  Yes 
     

  •  NO

React Js is developed by 

  •  Google 
     

  • Microsoft 
     


  • Facebook 
     

  • None of above 

A class component must include the _______ statement. 
 

  • extends React.Component 

     


  • extends React 
     


  • extends Component 
     


  • extends React.Component.All