- So the first thing we're going to be doing in this course
is building the front-end of our E-commerce site using Vue.
But before we get started though,
you might be wondering why we'd choose
to use Vue in the first place.
Well, the first question there
is why we'd want to use a front-end library at all,
instead of just creating our site
using basic HTML, CSS, and JavaScript?
or instead of using some other low-code solutions,
such as WordPress or Wix?
Well, compared to hand coding a site,
full-featured, front-end libraries,
such as Vue have many advantages.
The main advantage that they provide
is that they make the task of creating a performant website
much simpler and faster without taking away
any of the fine grain control from the programmer.
They allow us to create modular, reusable components
that can then be arranged into a fully functional website
instead of hand coding each individual page in our site.
Let's imagine for example,
that we have a blog site with a hundred articles,
each with pretty much the same structure.
What if we wanted to add a sign up form
to the top of all of our pages?
Well, if our site was just a collection of HTML documents,
we'd have to make the same exact change
to a hundred separate files,
which is not a pleasant task
by any stretch of the imagination.
With front-end libraries, such as Vue on the other hand,
all of our pages would be based on a reusable page component
that simply loads different data,
depending on what page we're on.
So we only have to make this change once
to see it across all the pages.
Now, the next question is
why you'd use a front end library like Vue
over low or no code platforms
like WordPress or Wix or Squarespace,
or any of those other website builders
that you see ads for on YouTube?
Well, first of all,
since this course is aimed primarily at developers,
if you want to create a blog
and you're not already a fairly strong developer,
I actually would recommend
that you use one of these platforms instead of Vue.
It'll probably end up being much more difficult
for you in the long run
if you try to create a code-based site with Vue
if you still struggle with basic coding concepts.
So, another question, and probably the most common question
that I get asked is why you choose Vue
over some of the other front-end frameworks
like React or Angular?
Now this may come as a shock to those who are looking
to learn "the best front-end library"
But in my opinion, there is no best front-end library.
And here's why,
like most other pointless debates
inside and outside the programming world
finding the best front-end library is extremely subjective.
So one developer may say
that Vue is hands down the best front-end library
another one may say that no React is.
And a third one might say that Angular is the best
or that Svelte or Ember
or one of the other ones is the best.
And what they actually mean
is that they've found the best library
for their own needs
or more commonly that, that's the only one
they've ever worked with.
And they therefore think it's the greatest.
That's a pretty common thing to run into as well
in this space.
Well, in my experience,
having worked pretty extensively with all three
of the major front-end libraries,
Am convinced that none of them are definitely the best.
Ultimately the best way to see what works for you
is to try all of them out for yourself,
try building the same apps using all three
and see what you like and don't like about each.
Now, all that being said,
a better question might be,
What is Vue's unique value proposition
compared to other libraries?
In other words,
what advantage does it provide
over libraries like Angular and React?
Well, as you can see,
just by going to the homepage of the website,
one of the unique things about Vue
is that it's designed
so that it can be incorporated incrementally
into existing websites.
One of the big pain points that many companies run into
with other libraries is that they want to adopt them
they want to convert their site over to React for example,
but doing so often requires them
to rebuild their entire site from scratch.
And then at some point in time,
they need to switch all the traffic
over from their old site to their new React site.
And this usually means a huge expense in time, money
and risk.
With Vue however we're able to switch
over a site much more gently.
We can switch our sites over to Vue in very small pieces.
For example, we can just switch over the navigation bar
or just a specific form or just a specific portion of a page
or whatever.
Without having to rebuild the entire site in Vue first.
Now, granted in this course,
we are going to be building our Vue front-end from scratch
but it's still good to be aware
of the unique advantages of Vue provides
over other libraries.
So with that knowledge,
let's move on to see
how we can quickly set up a Vue powered front-end
for our web application.