< Return to Video

How to Install and setup React using vite 2025 | EZ Developer Tutorial

  • 0:00 - 0:02
    Hey developers!
  • 0:02 - 0:05
    In this video, I'm going to show you how to install
  • 0:05 - 0:08
    React app using vite in your project.
  • 0:08 - 0:12
    So for that, first of all, I'm going to my
    browser.
  • 0:12 - 0:16
    And search vite.dev which is the official
    documentation
  • 0:16 - 0:19
    Of vite.
  • 0:19 - 0:23
    So here if you scroll down, you will see the command line that is used
  • 0:23 - 0:28
    to install the React app. npm create vite at latest.
  • 0:29 - 0:33
    So copy this line and go to command prompt
    of your PC.
  • 0:35 - 0:38
    And then, paste the line in the
    command prompt.
  • 0:38 - 0:40
    And press enter.
  • 0:48 - 0:51
    And then again, press enter.
  • 0:56 - 0:58
    And now, you have to give a project
    name.
  • 0:58 - 1:05
    So, I'm giving first react project.
  • 1:09 - 1:11
    And then press enter and now we have to
    select a framework.
  • 1:11 - 1:13
    Which is react of course.
  • 1:13 - 1:20
    Now we have to select a variant which is JavaScript. XML, JSX.
  • 1:21 - 1:24
    Now, we have to change our
    directory to the first
  • 1:24 - 1:26
    react project folder.
  • 1:26 - 1:31
    So, let's copy this line and paste it
    again in the command prompt.
  • 1:31 - 1:34
    And-- And press enter.
  • 1:34 - 1:41
    Now, npm install in order to install
    all the required packages
  • 1:41 - 1:45
    For the react-- react project.
  • 1:46 - 1:51
    It will automatically install all the necessary
    packages that you will need.
  • 1:51 - 1:53
    In your react app.
  • 1:53 - 2:00
    Now, based on your internet--
    internet speed, it will take a few moments.
  • 2:03 - 2:07
    And make sure you have already downloaded
    node.js.
  • 2:09 - 2:13
    So, it's now installing all the
    packages.
  • 2:16 - 2:18
    And yeah. They've installed.
  • 2:18 - 2:22
    And now, before typing npm
    run dev.
  • 2:22 - 2:25
    Let's go to our visual studio code.
  • 2:26 - 2:29
    And again go to our command prompt.
  • 2:30 - 2:34
    And type npm run dev.
  • 2:35 - 2:37
    And then press enter.
  • 2:37 - 2:41
    Now, you will-- you will see there's--
    we have got a link.
  • 2:41 - 2:45
    The local host. Now you can copy
    this one or press the control button.
  • 2:45 - 2:49
    Of your keyboard and then
    click on the link.
  • 2:49 - 2:52
    And a new page will be opened in your browser.
  • 2:53 - 2:59
    If your page-- if your window looks like this,
    then your react project is ready.
  • 2:59 - 3:03
    Now, to check this, you go to the
    VS code in the src folder.
  • 3:03 - 3:11
    In app.jsx. Let's delete something from-- from this folder-- from this file.
  • 3:12 - 3:15
    Let's delete this div.
  • 3:15 - 3:18
    To check whether it works or not.
  • 3:18 - 3:21
    Now save it and go to the browser.
  • 3:22 - 3:24
    Yeah, it works!
  • 3:24 - 3:25
    Let's check it again.
  • 3:25 - 3:34
    Let's say, we write here h1. h1 tag
    and inside it, let's write, "Hello world"
  • 3:34 - 3:42
    Um... this is my first react project
    using vite.
  • 3:43 - 3:46
    Now save it.
    And again go to the browser.
  • 3:47 - 3:49
    Yeah, it works!
  • 3:49 - 3:55
    So, this is how you install
    react app in your-- to use in your project.
  • 3:55 - 3:57
    Using vite.
  • 3:57 - 4:01
    And that's all for today. Don't forget
    to like this video.
  • 4:01 - 4:05
    And comment down to share your
    thoughts.
  • 4:05 - 4:06
    Have a good day!
Title:
How to Install and setup React using vite 2025 | EZ Developer Tutorial
Description:

more » « less
Video Language:
English
Duration:
04:09

English subtitles

Revisions Compare revisions