WEBVTT

00:01.680 --> 00:04.400
We can save it and then create the shareholder.

00:05.120 --> 00:08.680
In order for that to be working, we would need to create an

00:09.180 --> 00:09.520
interface first.

00:12.560 --> 00:15.920
So export interface,

00:16.240 --> 00:24.720
shareholder. The what?

00:25.220 --> 00:28.390
Name, email and company's own. Right.

00:28.890 --> 00:29.070
So name,

00:33.150 --> 00:37.830
email and company's own would

00:38.330 --> 00:42.390
be a separate type which we

00:42.890 --> 00:49.430
will create and then we

00:49.930 --> 00:54.200
will create a separate interface also for that which would be only company

00:54.440 --> 00:57.160
ID which is a string.

00:58.840 --> 01:02.280
Because we plan to share it, we don't need necessarily to refer

01:02.780 --> 01:06.320
it and Smango DB model and we will have shares to

01:06.820 --> 01:10.400
reflect how many shares of specific company the shareholder has. And then

01:10.900 --> 01:14.400
we can command GitHub copilot and then let's see what it will create. So we

01:14.900 --> 01:18.760
will have name, email, company zoned and we need

01:19.260 --> 01:23.020
to import it company so company id.

01:23.820 --> 01:27.500
It's actually we do not want specifically here to refer to a

01:28.000 --> 01:30.860
company because we don't want to fetch it at least yet.

01:31.260 --> 01:33.740
And then it would be required.

01:36.059 --> 01:39.180
True. And we also need to

01:39.980 --> 01:43.460
create a model which for the default shareholder.

01:43.960 --> 01:47.300
So you can see that GitHub Copilot is actually good in generating the boilerplate.

01:47.800 --> 01:51.230
So we have this one. So we would need to fix this shareholder issue here

01:51.730 --> 01:55.910
by importing it. And so now we have models and we have MongoDB connected

01:56.150 --> 02:00.070
so we can actually go further and create the routes

02:00.550 --> 02:03.220
which going to be used by our service and.
