Hey guys, welcome back!
I'm going to do this video
I wasn't going to
but I decided to do it,
as this is a module for developers and I think the information
you'll find in this video is going to be really helpful for you.
And so, it's going to be a more in depth look at Meteor
and how to use it in your next projects.
So it's a tutorial of some sort.
And so, I'm going to be showing you guys
how to use Meteor with React and Flow Router.
And I find that there's not too much information out there on
this combination of tools and so it makes sense to give you guys
that information. If you're following along this course anyway
you know, I think it's quite reasonable to assume that some of you
will at least are going to need this information.
And even if you didn't know you needed it,
maybe you can go ahead and use Meteor in your next project.
So in the last video,
we created a project through Terminal
from Meteor. So what I'm going to do now is
I'm going to open up a Terminal.
And I'm going to change Directory to Projects.
And into To Do.
And so,
Meteor automatically creates a few files for you first.
So let's go ahead and open this up in Webstorm.
I'm going to click Open,
and down into Projects,
to To Do, hit Okay,
and Webstorm is going to open up the Project.
And we've got the Project View on the left hand side.
So the first thing we're going to do is delete these files.
'Cause we don't need them.
Now we're going to start creating some Directories.
Because in Meteor, Projects can get farely large
because you're going to be working with a lot of files.
And so organization is a huge
benefit here, so.
Let's right click and create a Directory called Client.
I'm going to create another Directory called Lib,
and one more for Server.
Now the Client's Directory is going to contain
everything that is going to be available to the client.
So this is where your templates and stuff are going to go.
So in Client, I'm going to create a new Directory called Components.
And this is where we are going to store
the React Components.
Now in Lib, what I'm going to do,
is create a file
called Router.jsx
And in the Router file, we're going to be defining routes for Flow Router.
So before we get to that, we actually need to add some Packages Project.
So in the Directory here in Terminal,
just type - meteor add react
and then - kadira:react-layout and kadira:flow-router
and hit Enter.
There we go, so we've got everything added in here.
I was having an issue with Jet Brains IDEs and basically it was a conflict
with open JDK,
and so in order to resolve those, I've installed Oracle Java.
And basically what was happening was,
when you start typing something, this auto suggestion box pops up
and that was causing the program to hang.
And so to resolve that,
what I had to do was,
add a repository to my system.
And I'm just going to search - webupd8 java.
And you're going to go to the launchpad.net page.
and in here just copy this
archive url there
and in terminal you can run - sudo
add-apt-repository
and then the repository name.
And you can actually start connecting multiple commands together.
So sudo-apt-get update,
and the way you connect commands together is
by using two ampersands between the commands.
Not basically says run command one and when that's done
if it's successful run command two, and if that's done,
run the next command, which is going to be sudo
apt-get install oracle-
java8-installer.
And so you are going to run that and that should resolve the issues
with Jet Brains IDEs if you're having the same as I was.
So let's get back to
in here. So let's start making some routes.