Font size
WorksheetsReact Intro
Total questions: 8
Worksheet time: 4mins
What is react?
Javascript framework for creating user interfaces
Javascript library for creating user interfaces
A programming language used for web app development.
Which one of the following is a way of creating react app?
npx create-react-app my-app
npm create vite@latest my-app --template react
All of the above
What is a component in React?
A function that only manages data storage in a React application.
A tool that converts JavaScript code into HTML and CSS for rendering the UI.
A reusable piece of UI that can manage its own content, logic, and styling, and can be combined with other components to build complex applications.
What is JSX in react?
JSX is a syntax extension for JavaScript that allows writing HTML-like code within JavaScript, making it easier to structure React components.
JSX is a JavaScript framework for handling backend logic in React
JSX is a CSS styling method used to apply styles directly within JavaScript in React.
What is the correct way to render a component called Home in React?
<Home />
<Home></Home>
{Home}
Which of the following is the correct way to import a component in React?
import './MyComponent' as MyComponent;
import MyComponent from './MyComponent';
How do you start a React app created with Vite?
Run npm start in the project directory.
Run npm run dev in the project directory.
Which one of the following is not a feature of React
Component based
All are correct
Has JSX syntax
