Well, we've built out a variety of different applications, but right now they can only be used on
our local machine.
So in this video and the coming videos, we're going to figure out how to change that.
We're going to deploy our applications online that our friends, family, employers, whoever else can
visit these applications and try them out on their own.
The first thing we're going to do is better understand what the deployment process looks like.
So we are making use of create react app built in to create react app is a command to build out our
project when we build our project.
It creates what is called a deployment bundle.
In this deployment bundle are a couple of different files that are required to run our project inside
of a browser.
So for example, the indexed HDMI file, a JavaScript files, VSS images and so on.
These are all static files and these are used for the actual deployment.
Don't use the term static files.
I mean, to say that these are just normal files that can exist inside of some folder or directory.
Up to this point in the course, we've been running create react app in development mode, which means
that there is a running development server when we build our project and build up this deployment bundle.
We no longer have a running server.
Instead, we just need to load these files into a browser to run our application.
So we are going to take those files and upload them to some kind of deployment target.
The deployment target right here is going to be the service that we used to deploy our application.
This might be whatever service provider we decide to deploy our app to.
This deployment target is going to take these files and host them.
Then whenever user types in our domain into their browser, their browser is going to make a request
over to our deployment provider and they're going to immediately get back response that contains always
the index dot.
Each temo file, that file will be loaded up inside the browser, and inside of it will be some variety
of script tags, linked tags and so on.
That will cause the browser to make additional requests and get some additional JavaScript files.
Or C SS files.
Now, one thing that's really critical for you to understand about the deployment of REACT application
is that we do not have to be running some kind of virtual machine or anything like that to deploy a
react application.
You only need a virtual machine if you're running some kind of active server, some kind of server that
is actively running some code.
So, for example, you might need a virtual machine if you're running a node J.S. API there.
The expectation here is that this virtual machine is going to run this server process and this server
will respond to incoming requests.
We do not need a virtual machine to deploy a react application because we are not executing any code
whatsoever on any server when we host our REACT application.
The only thing we are hosting are these very plain static files.
These files would be equivalent to just uploading a couple of images and then downloading them over
time.
That's what you really want to think about.
And we start to deploy a react application.
This is very important to understand, because it means that it costs dramatically less to deploy in
a react application than it does to deploy something like a no J.S. server or API.
Virtual machines cost a lot of money to rent and run every month.
But hosting static files like what we're going to do with our REACT application is usually very, very
cheap or even more frequently just plain free.
All right, so now we've got a little overview.
We're going to start to take a look at our first deployment provider in the next video.