1
00:00:01,170 --> 00:00:06,750
All right, my friends, I'm back at my code editor inside my book directory, and those are three packages

2
00:00:06,750 --> 00:00:07,200
right there.

3
00:00:07,730 --> 00:00:11,650
So as you'd guess, we have to go through all these different steps for all three different packages.

4
00:00:11,910 --> 00:00:13,260
Don't worry, it's not going to be that bad.

5
00:00:13,480 --> 00:00:15,660
We pretty much have a good idea of what we need to do.

6
00:00:15,660 --> 00:00:20,490
So let's just get right to it that no one here make sure our package names are unique.

7
00:00:20,940 --> 00:00:26,340
That means we have to go round to all three of our different packages on files and make sure that whatever

8
00:00:26,340 --> 00:00:31,380
we have written inside there for the name is a unique unus name on the NPM registry.

9
00:00:32,100 --> 00:00:36,590
Well, I can just about guarantee you that the name Seelie is probably already in use.

10
00:00:37,020 --> 00:00:41,250
Let's go back over to and just come inside of our browser and just verify that is the case.

11
00:00:43,100 --> 00:00:45,020
So back at 9pm Dotcom.

12
00:00:46,090 --> 00:00:51,220
I'll do a search for Seelie and yes, it definitely looks like there is already a package published

13
00:00:51,220 --> 00:00:56,740
called Zeolite, that means that I cannot make use of the name Seelie and I'll need to think of some

14
00:00:56,740 --> 00:00:57,430
different name.

15
00:00:58,150 --> 00:01:02,650
In this case, I've decided to use the name James Note short for Jass Notebook.

16
00:01:03,220 --> 00:01:04,900
So if I search for jazz note.

17
00:01:05,730 --> 00:01:11,070
Yep, definitely, it looks like this is not in use just yet, there are some very similarly named projects,

18
00:01:11,280 --> 00:01:14,190
but there's no existing package called Jazz Note.

19
00:01:14,460 --> 00:01:16,680
So I can make use of this package name.

20
00:01:17,880 --> 00:01:20,520
So for my Seelie, I'm going to rename.

21
00:01:21,890 --> 00:01:28,040
DLI right there to just note now, once again, remember, I am making use of Jass notes, only one

22
00:01:28,040 --> 00:01:29,540
person can use this package name.

23
00:01:29,810 --> 00:01:33,490
That means that you are going to have to think of a different package name.

24
00:01:34,010 --> 00:01:37,180
It can be just notes, mine jazz note.

25
00:01:37,280 --> 00:01:38,990
Hey, ASDF, whatever you want.

26
00:01:38,990 --> 00:01:40,250
It just cannot be.

27
00:01:40,250 --> 00:01:41,090
Just note.

28
00:01:43,620 --> 00:01:49,530
Now, we can repeat that same process for our other two packages on files, so we've got local API and

29
00:01:49,530 --> 00:01:55,380
local clients, but before we just go and try to find some unique package names for those two, just

30
00:01:55,380 --> 00:01:56,420
one quick note here.

31
00:01:56,910 --> 00:02:02,240
Remember, local API and local client are really only consumed by our Seelie package.

32
00:02:02,610 --> 00:02:07,710
So in other words, I don't really anticipate anyone is ever going to directly install local API onto

33
00:02:07,710 --> 00:02:08,289
their machine.

34
00:02:08,610 --> 00:02:09,930
I just don't think that's going to happen.

35
00:02:10,350 --> 00:02:12,290
Same thing for local client as well.

36
00:02:12,300 --> 00:02:16,430
I don't think anyone is going to try to manually install local client onto their machine.

37
00:02:17,130 --> 00:02:22,290
The one thing we can do to logically group together these different packages on NPM and just make it

38
00:02:22,290 --> 00:02:27,930
very clear to you and I that these packages are all somehow grouped together or used together, is assigned

39
00:02:27,930 --> 00:02:30,990
these packages to what is called an organization.

40
00:02:32,340 --> 00:02:38,010
Another term for this is to create a scoped package, you already make use of scope packages all the

41
00:02:38,010 --> 00:02:39,500
time without really realizing it.

42
00:02:39,540 --> 00:02:42,930
Or maybe, of course you do inside of my local API package.

43
00:02:43,080 --> 00:02:43,800
JSON file.

44
00:02:45,290 --> 00:02:49,130
I'm going to scroll down and go to the dependency section inside of here.

45
00:02:49,160 --> 00:02:55,910
You'll notice we have eight types, of course, and at Types Express, these are scoped packages.

46
00:02:56,180 --> 00:02:59,690
In this case, the organization that owns these packages is types.

47
00:02:59,930 --> 00:03:01,670
That is the name of the organization.

48
00:03:03,190 --> 00:03:10,330
By naming a package as a scope package, it just makes it very clear that at Type Korzen, at Type Express

49
00:03:10,330 --> 00:03:13,060
or somehow related or managed by the same team.

50
00:03:13,570 --> 00:03:18,610
So we might want to use a very similar pattern in our case and just make it very clear that local API

51
00:03:18,700 --> 00:03:21,390
and local client are somehow tied together in some way.

52
00:03:22,220 --> 00:03:28,190
However, we still might want to allow the ally to be named Jesus note or something very similar, we

53
00:03:28,190 --> 00:03:32,810
might not want to scope this package just to keep the name of this package very simple and straightforward.

54
00:03:33,020 --> 00:03:34,430
But people don't have to memorize.

55
00:03:34,550 --> 00:03:40,430
Oh, yeah, I've type in at just notes, whatever, at their terminal whenever they tried to run Arkley.

56
00:03:41,330 --> 00:03:43,300
So long story short, here's my idea.

57
00:03:44,260 --> 00:03:46,270
I think we should do something like this.

58
00:03:46,830 --> 00:03:52,150
I'm going to leave Seelie name does just note, but I'm then going to create some organization called

59
00:03:52,150 --> 00:03:52,990
Jazz Note.

60
00:03:54,230 --> 00:04:00,030
And I'm going to rename local API and local client to be scoped packages within that organization.

61
00:04:00,800 --> 00:04:04,820
Now, of course, these names or the name of the organization in this case is going to be different

62
00:04:04,820 --> 00:04:07,280
for you because very similar to package names.

63
00:04:07,280 --> 00:04:10,030
Organization names have to be unique on NPM as well.

64
00:04:11,560 --> 00:04:17,950
So you might end up with something like just note dash mine or just notes ASDF or whatever else you

65
00:04:17,950 --> 00:04:18,600
want to put in there.

66
00:04:19,570 --> 00:04:23,710
Now, one thing I just want to repeat here is that this is not strictly required, it's just a pattern

67
00:04:23,720 --> 00:04:28,360
you're going to see very frequently, again, just to kind of logically grouped together packages and

68
00:04:28,360 --> 00:04:31,390
make it clear that these things all kind of belong together in some way.

69
00:04:32,810 --> 00:04:34,260
OK, so that's the general idea.

70
00:04:34,310 --> 00:04:35,300
Let's take a pause right here.

71
00:04:35,310 --> 00:04:40,430
We'll come back to the next video and we're going to create an organization to house our local and local

72
00:04:40,430 --> 00:04:41,390
client packages.

