Ext JS/React JS MCQ Sample Test,Sample questions

Question:
 .............. helps react for keeping their data unidirectional.

1.JSX

2.Flux

3.Dom

4.Props

Posted Date:-2022-08-05 11:51:35


Question:
 In React what is used to pass data to a component from outside?

1.setState

2. render with arguments

3.props

4.Types

Posted Date:-2022-08-05 09:58:28


Question:
 Mit welchem Befehl starten wir die React App?

1.npm run dev

2. npm serve

3.npm start

4. npm build

Posted Date:-2022-08-05 11:54:13


Question:
 Variabel yang dapat dipanggil di dalam komponen lain dalam React JS dan juga menghubungkan Komponen satu dengan yang lain

1.props

2.state

3.var

4.const

Posted Date:-2022-08-05 12:22:21


Question:
 What happens when the following render() method executes?<br /><br /> render(){<br /> let langs = ["Ruby","ES6","Scala"]<br /> return (<div><br /> {langs.map(it => <p>{it}</p>)}<br /> </div>)<br /> }<br />

1.Displays the list of languages in the array

2.Error. Cannot use direct JavaScript code in JSX

3.Displays nothing

4.Error. Should be replaced with a for..loop for correct output

Posted Date:-2022-08-05 10:15:29


Question:
 What is a controlled input element?

1.An input element with the controlled flag

2.An input element that is controlled by the value of another input element

3.An input element that can only accept a list of characters

4.An input element whose value is being controlled by a component’s state

Posted Date:-2022-08-05 10:10:15


Question:
 What is state in React?

1.A persistant storage.

2.An internal data store (object) of a component.

3.both (a) and (b)

4.None of the above

Posted Date:-2022-08-05 11:31:39


Question:
 What was the Output?const [data , setData] = useState("Alex");console.log(data);

1.data

2.data

3.Alex

4. none of the above

Posted Date:-2022-08-05 12:03:09


Question:
At the highest level, React components have lifecycle events that fall into

1.Initialization

2.State/Property Updates

3.Destruction

4.All of these

Posted Date:-2022-08-05 10:00:50


Question:
Axios is an __________?

1.Framework

2.Library

3.Package

4.All These Above

Posted Date:-2022-08-05 11:50:51


Question:
Everything in react is

1.Package

2.Model

3.Method

4.Component

Posted Date:-2022-08-05 11:19:53


Question:
How do you write an inline style specifying the font-size:12px and color:red; in JSX

1.style={{font-size:12,color:'red'}}

2.style={{fontSize:'12px',color:'red'}}

3.style={fontSize:'12px',color:'red'}

4. style={{font-size:12px,color:'red'}}

Posted Date:-2022-08-05 10:03:04


Question:
How many elements does a react component return?

1.Elements

2.1 Element

3.Multiple Elements

4.None of These

Posted Date:-2022-08-05 10:02:02


Question:
In which directory React Components are saved?

1.Inside js/components/

2.Inside vendor/components/

3.Inside external/components/

4.Inside vendor/

Posted Date:-2022-08-05 09:59:35


Question:
Life cycle methods of a components fall under following categories?

1.Mounting, Unmounting

2.Mounting, Updating

3.Mounting, Updating, Unmounting

4.All of the above

Posted Date:-2022-08-05 11:32:38


Question:
One can define default values for properties, props, using which of the following method?

1.getDefaultProps

2.getPropsValue

3.getInitialState

4.None of these

Posted Date:-2022-08-05 11:37:17


Question:
Penulisan kode yang benar untuk array function

1.tambah = () = {}

2.tambah = () => {}

3. tambah = []

4.tambah = {}

Posted Date:-2022-08-05 12:09:08


Question:
Penulisan Sintaks dengan ekstensi Java Script yang benar adalah

1.onChange dan classname

2.className dan onClick

3.onclik dan OnChange

4.none of the above

Posted Date:-2022-08-05 12:19:50


Question:
Perulangan dalam React JS dapat dilakukan dengan menggunakan

1.map

2.looping

3.loop

4.mapping for

Posted Date:-2022-08-05 12:06:31


Question:
React is for building _________

1.Connectivity

2.User Interface

3.Database

4.All of the above

Posted Date:-2022-08-05 11:56:43


Question:
React JS memiliki sintaks ekstensi javascript yang disebut dengan

1.XML

2.HTML

3. JSE

4.JSX

Posted Date:-2022-08-05 12:17:28


Question:
React JS merupakan

1.bahasa pemograman server-side Java Script

2.framework User Interface PHP

3.framework User Interface Java

4.framework User Interface Java Script

Posted Date:-2022-08-05 12:18:34


Question:
React.Js is a __________?

1.Framework

2.Library

3.both (a) and (b)

4.None of these.

Posted Date:-2022-08-05 11:58:40


Question:
React.Js was created by ___________?

1.Google

2.Microsoft

3.Facebook

4.All of above

Posted Date:-2022-08-05 11:59:27


Question:
Salah satu jenis Router dalam React JS

1.SearchRouter

2.FindRouter

3.BrowserRouter

4.GetRouter

Posted Date:-2022-08-05 12:15:51


Question:
There are two types of components in React JS

1.UseState, Stateless

2.Statefull, Stateless

3.Unstatefull Statefull

4.None of these

Posted Date:-2022-08-05 11:49:40


Question:
Untuk menghubungkan Back-End dan Front-End diperlukan penggunaan __

1.API

2.render

3. Both A & B

4.none of the above

Posted Date:-2022-08-05 12:20:42


Question:
Variabel default React JS

1.Props

2.Statefull

3.Stateless

4.State

Posted Date:-2022-08-05 11:47:00


Question:
What are the two ways that data gets handled in React?

1.state & props

2.services & components

3.Both A and B

4.None of These

Posted Date:-2022-08-05 11:18:56


Question:
What function allows you to render React content in an HTML page?

1.React.mount()

2.ReactDOM.start()

3.ReactDOM.render()

4.React.render()

Posted Date:-2022-08-05 11:20:56


Question:
What function can be used to update state?

1.setState()

2.updateState()

3.upState()

4.downState()

Posted Date:-2022-08-05 11:22:59


Question:
What is a good use case for using a function while rendering a dynamic list of items

1.If we need to compute a value based on properties of items in the loop.

2.None. Functions should not be used while rendering a dynamic list.

3.To make the code shorter

4.None of the above

Posted Date:-2022-08-05 10:04:27


Question:
What is a good use case for using a function while rendering a dynamic list of items

1.If we need to compute a value based on properties of items in the loop.

2.None. Functions should not be used while rendering a dynamic list.

3.To make the code shorter

4.None of the above

Posted Date:-2022-08-05 10:04:28


Question:
What is Axios in Node?

1.npm component

2.Promise based HTTP client for the browser and node.js

3.A company

4.None of these

Posted Date:-2022-08-05 11:57:54


Question:
What is JSX?

1.it is a syntax extension to JavaScript.

2.JSX produces data.

3.Tool to control the data

4.None of the above

Posted Date:-2022-08-05 11:21:53


Question:
What is React.Js used for?

1.Server-Side

2.Client-Side

3.For Both

4.None of these

Posted Date:-2022-08-05 12:01:24


Question:
What is ReactJS?

1.Server side Framework

2.User-interface framework

3.A Library for building interaction interfaces

4.None of the above

Posted Date:-2022-08-05 11:55:44


Question:
What is the DOM?

1.Document Object Model

2.Data Object Model

3.Data Option Model

4.Documentation Object Model

Posted Date:-2022-08-05 11:46:19


Question:
What is the second argument for setState useful for?

1.To invoke code after the setState operation is done

2.To replace the state completely instead of the default merge action

3.To access the previous state before the setState operation

4.None of the above

Posted Date:-2022-08-05 10:12:13


Question:
When it is recommended to pass this.setState as a function instead of an object?

1.When the new state should completely replace the old state

2.When the new state depends on the old state

3.When the new state does not depend on the old state

4.None of the above

Posted Date:-2022-08-05 11:28:52


Question:
Which concept includes OOP's?

1.Functional Components

2.Class Components

3.Oriented Components

4.None of the above

Posted Date:-2022-08-05 12:00:28


Question:
Which method is not part of ReactDOM?

1.ReactDOM.destroy()

2.ReactDOM.hydrate()

3.ReactDOM.createPortal()

4.ReactDOM.findDOMNode()

Posted Date:-2022-08-05 10:07:48


Question:
Which of the following API is a MUST for every ReactJS component?

1.getInitialState

2.render

3. renderComponent

4.None of the above

Posted Date:-2022-08-05 10:08:41


Question:
Which of the following below act as the input of a class-based component?

1.class and factory

2.render and mount

3.props

4.none of the above

Posted Date:-2022-08-05 11:30:19


Question:
Which of the following is correct syntax for a button click event handler, foo?

1.<button onclick=this.foo()>

2.<button onclick=this.foo>

3.<button onClick={this.foo()}>

4.<button onClick={foo}>

Posted Date:-2022-08-05 10:06:28


Question:
Which of the following is correct syntax for a button click event handler, foo?

1.<button onclick=this.foo()>

2.<button onclick=this.foo>

3.<button onClick={this.foo()}>

4.<button onClick={foo}>

Posted Date:-2022-08-05 10:06:28


Question:
Who Develop React.js?

1.Apple

2.Facebook

3.Twitter

4.Google

Posted Date:-2022-08-05 11:24:27


Question:
Who is the father of React.js?

1.Jordan mike

2.Jordan Walke

3.Nile

4. Nike John

Posted Date:-2022-08-05 11:52:49


Question:
_____ Home from './components/Home';Lengkapi Code di atas

1.import

2.di atas

3.Both A & B

4.none of the above

Posted Date:-2022-08-05 12:16:48


More MCQS

  1. React JS MCQ
  2. AngularJs MCQ
Search
R4R Team
R4Rin Top Tutorials are Core Java,Hibernate ,Spring,Sturts.The content on R4R.in website is done by expert team not only with the help of books but along with the strong professional knowledge in all context like coding,designing, marketing,etc!