- [Emmanuel] As mentioned before, the package.jsn file is
the map for building your project
and setting your dependencies, but first, let's take a look
at what you need to follow along.
All you need is a good editor with some
terminal capabilities, and VS code is perfect for this.
So go to code.visualstudio.com, and once you get to
the website, it should recognize your operating system.
So download this particular version, and install it.
Once you have it installed, it should look
something like this, so you can close the welcome screen
and what we're gonna do first is create the brand new folder
on our desktop or wherever you want,
and I'm gonna call this npm.
You can call this anything you want,
this is our practice folder, and in the exercise files,
click on resources, and you should have two files here.
If you don't see this file here, it's because you don't have
the hidden files showing in your system.
So, do a research on the web, how to show hidden files
and then once you have those two files,
copy them and then place them in the new folder called npm.
And then what we'll do is simply go back to VS Code,
click on "explorer", open folder,
and then grab the npm folder.
And now you should see those two files,
the babelrc and the index, and this is primarily
a quick project that I've done in the past,
and we're gonna use these files to do this course.
Okay, so the first thing we need to do is create
the package.jsn files, so the map for npm.
So let's go ahead and bring up the terminal in VS Code,
so I'm gonna click on "View", "Terminal",
and what I'm gonna do next is npm init, which is the
base command to initialize a new package.jsn file.
So, all the next questions are related to
what is going to be written inside of your package.jsn file.
So the first is the package name, so, so please
pay extra attention to the name here, because what you named
this package is what is going to be published to npm.
So if you name something, for example, npm,
well there must be a npm package somewhere in there,
so you wanna do something else.
And of course we're not going to publish this package,
but if you were, make sure you pay attention to the name.
So what I would do, is do a search in the npm directory
to find out if yes or no, there is a package that exists.
The version number is fine, description, test project,
or whatever description you wanna do.
Entry point is the first file that's going to be launch,
and it's this one, then yes, we're good.
Test command, we're not going to use it for now.
Git repository, if you were to send this to a git repository
you would put the address there.
Keywords, and those keywords are for
search capabilities when you publish.
The author, and then the licensing, and you can take a look
at the licensing in documentation,
but I'm gonna stay with the standard, and then click "yes".
So let's close the terminal,
and right now we have a package.jsn file.
And in this package.jsn file we have the name, the version,
the description, the main file that's going to be launch,
a test script, and we'll talk about scripts later on,
the author, and license.
So this is the base package.jsn file, so once we start
installing new packages, you're gonna see them appear
in this file, and we're gonna take a look at it
as we do that, so let's move on.