install react js and create react app
To create a new React application, you'll need to have Node.js and npm (Node Package Manager) installed on your system. If you haven't installed them yet, you can download Node.js from the official website: https://nodejs.org/en/download/
Once you have set up Node.js and npm, you can use the "Create React App" command-line tool to create a new React app. This tool provides a boilerplate setup for a React application.
एक नया रिएक्ट ऐप बनाने के लिए, आपको अपने सिस्टम पर Node.js और npm (नोड पैकेज मैनेजर) इंस्टॉल करना होगा। यदि आपने उन्हें अभी तक इंस्टॉल नहीं किया है, तो आप आधिकारिक वेबसाइट से Node.js डाउनलोड कर सकते हैं: https://nodejs.org/en/download/ एक बार जब आपके पास Node.js और npm सेटअप हो जाए, तो आप "क्रिएट रिएक्ट ऐप" कमांड-लाइन टूल का उपयोग करके एक नया रिएक्ट ऐप बना सकते हैं, जो रिएक्ट एप्लिकेशन के लिए बॉयलरप्लेट सेटअप प्रदान करता है। Here are the steps to create a new React app: Step 1: Open your terminal or command prompt. (
चरण 1: अपना टर्मिनल या कमांड प्रॉम्प्ट खोलें।) Step 2: Install the create-react-app globally (if you haven't already) using npm: चरण 2: एनपीएम का उपयोग करके विश्व स्तर पर create react app इंस्टॉल करें (यदि आपने पहले से नहीं किया है)
bashnpm install -g create-react-app
Step 3: Create a new React app using Create React App: चरण 3: क्रिएट रिएक्ट ऐप का उपयोग करके एक नया रिएक्ट ऐप बनाएं:
bashcreate-react-app my-react-app
Replace "my-react-app" with your desired project name. This command will create a new folder named "my-react-app" with the basic structure and necessary files for your React application. Step 4: Navigate to the newly created app folder: "my-react-app" को अपने इच्छित प्रोजेक्ट नाम से बदलें। यह कमांड आपके रिएक्ट एप्लिकेशन के लिए मूल संरचना और आवश्यक फ़ाइलों के साथ "माय-रिएक्शन-ऐप" नामक एक नया फ़ोल्डर बनाएगा। चरण 4: नव निर्मित ऐप फ़ोल्डर पर नेविगेट करें:
bashcd my-react-appStep 5: Start the development server:(चरण 5: विकास सर्वर प्रारंभ करें:)
bashnpm start
This command will start the development server and open your React app in your default web browser at http://localhost:3000/. Any changes you make to the code will automatically be reflected in the browser. That's it! You now have a basic React app up and running. You can start building your components and adding your logic to create your web application. The project structure and configuration are all set up by Create React App, so you can focus on coding your application's features. यह कमांड डेवलपमेंट सर्वर शुरू करेगा और आपके रिएक्ट ऐप को आपके डिफ़ॉल्ट वेब ब्राउज़र में खोलेगा http://localhost:3000/। आपके द्वारा कोड में किया गया कोई भी परिवर्तन स्वचालित रूप से ब्राउज़र में दिखाई देगा। इतना ही! अब आपके पास एक बुनियादी रिएक्ट ऐप चालू है। आप अपना वेब एप्लिकेशन बनाने के लिए अपने घटकों का निर्माण और अपना तर्क जोड़ना शुरू कर सकते हैं। प्रोजेक्ट संरचना और कॉन्फ़िगरेशन सभी क्रिएट रिएक्ट ऐप द्वारा स्थापित किए गए हैं, ताकि आप अपने एप्लिकेशन की सुविधाओं को कोड करने पर ध्यान केंद्रित कर सकें।