00:00:13.966 --> 00:00:16.347 That's part of it, and I don't think the PM's will get much out
\00:00:16.347 --> 00:00:17.686 of that. Would they? Or would they?
\00:00:19.106 --> 00:00:22.045 I have. Yeah, the development team and and maybe a PM if
\00:00:21.886 --> 00:00:23.726 Yeah, so PM's are good to.
\00:00:22.045 --> 00:00:25.396 they're doing testing you could you could I mean, But yeah, it's
\00:00:25.396 --> 00:00:27.406 mostly for the development team, yeah.
\00:00:25.716 --> 00:00:28.286 It's good to know about as long as it's quick.
\00:00:27.156 --> 00:00:31.178 High level take away is that we have an internal server to test
\00:00:27.426 --> 00:00:27.766 OK.
\00:00:31.178 --> 00:00:34.697 SMTP without having to use personal SMTP to go and that
\00:00:34.697 --> 00:00:35.576 sort of thing.
\00:00:36.126 --> 00:00:40.665 Correct it. Well it can. Yes it can relay mail and you can use
\00:00:36.276 --> 00:00:36.906 Yes, Sir.
\00:00:37.256 --> 00:00:38.536 Bravo, sweet.
\00:00:40.665 --> 00:00:45.347 it for testing on your projects. You can make an inbox for every
\00:00:45.347 --> 00:00:50.030 project, doesn't matter. And if they're easy. So yeah, I'll show
\00:00:50.030 --> 00:00:54.352 you guys real quick and we can move on to the next. So I'll
\00:00:54.352 --> 00:00:58.026 post the URL, but it's mail.clarityhipaa.com we'll
\00:00:57.716 --> 00:01:00.413 And NPMS, you're welcome to skadoodle from here and thank
\00:00:58.026 --> 00:00:58.386 take.
\00:01:00.413 --> 00:01:02.366 you Ben JAMA, for shredding through this.
\00:01:02.676 --> 00:01:03.356 Absolutely.
\00:01:03.466 --> 00:01:03.976 Thanks all.
\00:01:04.596 --> 00:01:05.086 Thanks.
\00:01:04.976 --> 00:01:08.588 Umm, so yeah mail mail.clarityhipaa.com will take
\00:01:08.588 --> 00:01:13.139 you here. On a side note, we can add any domain we control. We
\00:01:13.139 --> 00:01:17.617 can make an inbox or we can make it a mail domain. But I just
\00:01:17.617 --> 00:01:21.734 chose this one because it wasn't being used for anything
\00:01:21.734 --> 00:01:22.456 otherwise.
\00:01:22.976 --> 00:01:27.216 Umm, so there's there's, uh two Webmail clients. This one is
\00:01:27.216 --> 00:01:28.466 called round cube.
\00:01:30.406 --> 00:01:34.913 And so this is kind of what that interface looks like. There's
\00:01:34.913 --> 00:01:38.990 another one that utilizes groupware, which, oops, sorry,
\00:01:38.990 --> 00:01:43.353 that's my personal one clarity. HIPAA called Sogo which this
\00:01:43.353 --> 00:01:46.786 basically emulates all of the functionality of.
\00:01:48.096 --> 00:01:49.836 Didn't like me of.
\00:01:52.166 --> 00:01:55.236 I would like a an outlook type of an inbox so.
\00:01:57.936 --> 00:01:59.806 Just gonna type it out here again.
\00:02:02.876 --> 00:02:05.056 Looks like that LastPass hack got you pretty good.
\00:02:02.926 --> 00:02:03.556 So.
\00:02:05.336 --> 00:02:06.886 And does it sometimes?
\00:02:07.966 --> 00:02:11.904 We're actually doesn't even fill in, but so as you can see this
\00:02:11.904 --> 00:02:15.841 this is integrates with Outlook. It's got a full blown calendar
\00:02:15.841 --> 00:02:16.456 task list.
\00:02:17.616 --> 00:02:21.889 I mean everything you can think of that in box should have. So
\00:02:21.889 --> 00:02:26.365 this is the front end of it from once you create one. So how do I
\00:02:26.365 --> 00:02:30.367 create one? Here's how you do that. There is an admin now.
\00:02:30.367 --> 00:02:34.640 Like I said, I'm gonna put all these details in new, clean us.
\00:02:34.640 --> 00:02:38.777 You don't have to memorize it. But it's I read admin this is
\00:02:38.777 --> 00:02:43.049 it's called I read mail and she just open source. So I'm going
\00:02:43.049 --> 00:02:47.186 to give everyone the share with the whole team the username.
\00:02:47.266 --> 00:02:50.029 And password for postmaster@clarityhipaa.com.
\00:02:50.029 --> 00:02:53.211 It's very important that we do not use postmaster at
\00:02:53.211 --> 00:02:56.574 clarityhipaa.com for anything other than administrative
\00:02:56.574 --> 00:03:00.417 purposes. There are a bunch of scripts and security things that
\00:03:00.417 --> 00:03:04.320 I have running and I get reports on them daily to this inbox and
\00:03:04.320 --> 00:03:08.223 I don't want to use for anything else other than logging in here
\00:03:08.223 --> 00:03:12.126 and creating an inbox to use for whatever your purposes are. So.
\00:03:13.156 --> 00:03:16.911 We'll have that available. Just don't, you know, use it for
\00:03:16.911 --> 00:03:20.665 anything other than this. And essentially when you come in,
\00:03:20.665 --> 00:03:24.357 you can see right now we just have the one domain. Keep in
\00:03:24.357 --> 00:03:28.298 mind, like I said, I can add as many domains as we own here if
\00:03:28.298 --> 00:03:32.053 the need ever arises. So keep that in mind. Currently, I've
\00:03:32.053 --> 00:03:35.682 got 7 users on here. We have put this to use some on some
\00:03:35.682 --> 00:03:39.186 projects, but it's very intuitive and I don't think you
\00:03:39.186 --> 00:03:42.126 guys really need a lot of training on this so.
\00:03:39.896 --> 00:03:43.744 Being can we just, can we just say that you and a handful of
\00:03:43.744 --> 00:03:47.276 other people are going to administer that and determine
\00:03:47.276 --> 00:03:51.439 who that will be so everyone can put that into a channel and they
\00:03:51.439 --> 00:03:55.097 can get an e-mail created by that subset of like three or
\00:03:53.786 --> 00:03:57.283 Yeah. And we can do, we can do that as well, but I definitely
\00:03:55.097 --> 00:03:56.106 four people, OK.
\00:03:57.283 --> 00:04:00.780 want the team in power to feel free to come in and do this as
\00:04:00.780 --> 00:04:04.108 well. It's just adding a user name password. That's it and
\00:04:02.896 --> 00:04:06.249 Then I think I think that that postmaster account would need to
\00:04:04.108 --> 00:04:04.446 we're.
\00:04:06.249 --> 00:04:09.497 be separated out or we would need to make a separate account.
\00:04:09.497 --> 00:04:12.850 So it's not. I just don't want everyone to have to know a bunch
\00:04:12.850 --> 00:04:13.426 of details.
\00:04:14.546 --> 00:04:17.376 Yeah, yeah, that's fine. I I, yeah, no problem.
\00:04:15.156 --> 00:04:15.586 Yeah.
\00:04:18.326 --> 00:04:18.696 Awesome.
\00:04:18.676 --> 00:04:22.457 So. So we can go that route and again, I mean I still if anyone
\00:04:22.457 --> 00:04:26.119 feels comfortable doing it, I totally am fine with that. It's
\00:04:26.119 --> 00:04:29.899 literally just for development purposes. But yeah, that's about
\00:04:28.766 --> 00:04:32.469 Do you want to say like 4, four or five folks? If you guys are
\00:04:29.899 --> 00:04:30.076 it.
\00:04:32.469 --> 00:04:36.348 interested in helping administer the e-mail and keep in mind this
\00:04:36.348 --> 00:04:37.876 is a convenience thing so.
\00:04:38.946 --> 00:04:42.091 You know, if you're one of the leaders on the team or you
\00:04:42.091 --> 00:04:45.453 generally like to help with that kind of thing or you want to
\00:04:45.453 --> 00:04:48.598 learn more about it, this would be a great opportunity as
\00:04:48.598 --> 00:04:52.123 probably not gonna take a lot of effort. Then it'll be very good
\00:04:52.123 --> 00:04:55.322 at. He's already walking you through here how to do it. So
\00:04:55.322 --> 00:04:58.684 Ping Ben directly if you would in chat and then he'll get you
\00:04:58.684 --> 00:05:02.046 set up and we can just have just a handful of folks accessing
\00:05:02.046 --> 00:05:05.570 that account. So we can sort of keep it pretty limited. And then
\00:05:05.406 --> 00:05:05.776 Sure.
\00:05:05.570 --> 00:05:08.932 anyone on the team will have the ability to ping into a group
\00:05:08.932 --> 00:05:12.294 channel and teams and just say, hey, we want you guys spin me
\00:05:12.294 --> 00:05:12.456 up.
\00:05:12.826 --> 00:05:16.381 This e-mail account and like you're saying Ben, you can use
\00:05:16.381 --> 00:05:20.233 it for any project, correct? So it would be like project acronym
\00:05:20.233 --> 00:05:23.076 at clarityhipaa.com or something like that. OK.
\00:05:21.186 --> 00:05:25.006 Correct. Mm-hmm. Exactly. Yeah. And you can see here, uh, like,
\00:05:25.006 --> 00:05:26.916 on the ones that we already had.
\00:05:28.276 --> 00:05:31.804 Let me go back to domains and I just created you one, but you
\00:05:31.804 --> 00:05:35.275 can see like we've got a Newton Group One, we've got one for
\00:05:35.275 --> 00:05:38.176 derm that we were using. And so yeah, I mean that.
\00:05:37.516 --> 00:05:39.791 Are you able to get additional domain? Sorry to keep
\00:05:39.791 --> 00:05:42.322 interrupting. Are you able to assign additional domains to
\00:05:40.206 --> 00:05:40.966 Absolutely.
\00:05:42.156 --> 00:05:45.534 Yes, Sir. Absolutely. And any domain that we own, I can do as
\00:05:42.322 --> 00:05:42.536 this?
\00:05:43.606 --> 00:05:47.576 Let's do like a clarity testing or something like that.
\00:05:45.534 --> 00:05:45.806 many.
\00:05:46.986 --> 00:05:48.166 Sure. OK.
\00:05:48.236 --> 00:05:53.086 So because I think clarity HIPPA is like hey, come attack us.
\00:05:50.996 --> 00:05:53.213 Well, if we can have Umm, clarity demos and clarity
\00:05:53.213 --> 00:05:54.406 client, that would be great.
\00:05:55.106 --> 00:05:57.036 Yeah, something like that. OK.
\00:05:55.266 --> 00:05:59.043 I can do that. I can make it. I can actually add clarity. Client
\00:05:59.043 --> 00:06:02.820 to I mean absolutely and that is great. That's kind of feedback.
\00:06:02.820 --> 00:06:04.156 I was hoping to get so.
\00:06:04.436 --> 00:06:06.696 Maybe, maybe just have a sub.
\00:06:05.526 --> 00:06:08.647 Because because I I think that does make make more sense. I
\00:06:08.647 --> 00:06:11.820 have another one that I use for like the hosting side that's
\00:06:11.820 --> 00:06:15.201 clarity host.com, but that that one isn't like for this purpose.
\00:06:15.201 --> 00:06:18.374 So it's guarded pretty heavily. But yeah, this is definitely
\00:06:18.374 --> 00:06:21.546 something we can add at any domain we want to it no problem.
\00:06:22.646 --> 00:06:24.126 But that that's basically it.
\00:06:22.706 --> 00:06:25.830 Does does this server support the ability with the have
\00:06:25.830 --> 00:06:28.506 usernames with the plus on them like in Google?
\00:06:27.926 --> 00:06:28.296 No.
\00:06:28.986 --> 00:06:29.306 No.
\00:06:29.986 --> 00:06:30.616 Nope.
\00:06:30.736 --> 00:06:31.936 Is that something you could add?
\00:06:32.656 --> 00:06:33.566 I don't know.
\00:06:34.566 --> 00:06:37.519 Don't know, maybe in fact, actually I might be able to do
\00:06:37.519 --> 00:06:39.606 that, but I doubt it. I'll look into it.
\00:06:41.926 --> 00:06:45.038 Because I I know that is is nice that we can do that with Gmail,
\00:06:45.038 --> 00:06:47.862 but I mean with this at least we can we can create as many
\00:06:47.862 --> 00:06:50.829 inboxes as we need and delete them when we're done. Whatever.
\00:06:50.829 --> 00:06:53.845 All that kind of stuff. But that can get a little cumbersome I
\00:06:53.845 --> 00:06:56.716 suppose I'll look into that for you James, because that is.
\00:06:57.486 --> 00:07:00.648 Good thing I I do like that for testing comes in handy when
\00:07:00.648 --> 00:07:03.968 you're like registering a bunch of accounts and trying to test
\00:07:03.968 --> 00:07:04.336 things.
\00:07:05.166 --> 00:07:06.276 So but yeah.
\00:07:05.666 --> 00:07:09.890 And Ben does this does this software have the the balance
\00:07:09.890 --> 00:07:10.326 table?
\00:07:11.156 --> 00:07:11.656 Yes.
\00:07:13.356 --> 00:07:15.856 Yep. So like uh.
\00:07:16.716 --> 00:07:21.193 If you're testing and, uh, you, I don't have it wired up using
\00:07:21.193 --> 00:07:25.385 like SMTP to go or anything which has that activity table.
\00:07:25.385 --> 00:07:28.226 It does track them internally in a log.
\00:07:29.326 --> 00:07:32.256 I I I think there's a way to see it on the front end.
\00:07:36.096 --> 00:07:39.844 I mean, I think that's probably the most useful thing that I've
\00:07:39.844 --> 00:07:43.006 seen so far out of SMTP to go is actually seeing the.
\00:07:44.406 --> 00:07:47.646 The balance and knowing when something's been sent.
\00:07:48.216 --> 00:07:52.051 Yep, now that you I I agree. I use that all the time for
\00:07:52.051 --> 00:07:56.086 troubleshooting mail. So I I will look into that and see if
\00:07:56.086 --> 00:08:00.391 there's an easy way to tell that because that I know that would
\00:08:00.391 --> 00:08:04.562 be helpful. And I mean I can also make this use SNTP to go as
\00:08:00.956 --> 00:08:01.166 OK.
\00:08:04.562 --> 00:08:08.665 the SMTP relay, but since we have all the ports available to
\00:08:08.665 --> 00:08:12.835 us necessary, I just made this machine do all the routing and
\00:08:12.835 --> 00:08:16.736 relaying and everything. But I'll look into that for ukb.
\00:08:17.216 --> 00:08:17.796 OK. Thank you.
\00:08:19.156 --> 00:08:20.766 Anybody else have any?
\00:08:21.436 --> 00:08:24.927 Questions, comments, concerns. That was that's basically just
\00:08:24.927 --> 00:08:28.248 it. I just wanted to let the team know that it's available
\00:08:28.248 --> 00:08:29.486 and that we have that.
\00:08:32.126 --> 00:08:32.526 Yeah.
\00:08:32.866 --> 00:08:34.696 That's awesome man. Thanks for setting it up for us.
\00:08:35.056 --> 00:08:38.273 Bet worse. More to come. More to come. I'm not even getting
\00:08:38.273 --> 00:08:38.916 started yet.
\00:08:42.636 --> 00:08:45.606 And that was the IT guys just let you guys know so.
\00:08:42.706 --> 00:08:42.996 That's.
\00:08:45.606 --> 00:08:46.426 You know for this.
\00:08:47.606 --> 00:08:48.936 Sweet.
\00:08:47.866 --> 00:08:48.106 Awesome.
\00:08:49.416 --> 00:08:52.328 Thanks, Ben. Anybody have any questions for Ben before we move
\00:08:52.328 --> 00:08:52.466 on?
\00:08:53.296 --> 00:08:54.206 Any other questions?
\00:08:55.186 --> 00:08:57.386 Once I do. But can you guys hear me?
\00:08:57.976 --> 00:08:58.286 Yeah.
\00:08:58.556 --> 00:08:58.756 Yep.
\00:08:58.786 --> 00:09:02.883 OK. Are you gonna spin up a nuclino for this, too? Have a
\00:09:02.883 --> 00:09:03.236 beer.
\00:09:03.236 --> 00:09:06.629 Yeah, I'm going to put all the details into clean. Oh, in the
\00:09:06.629 --> 00:09:10.240 in the. It'll be in the the same one that you guys go to for that
\00:09:10.240 --> 00:09:13.413 has like sendgrid and SMTP on it. I'll have a link to the
\00:09:13.413 --> 00:09:15.546 details on this as well. So it's just.
\00:09:16.246 --> 00:09:19.811 More added to our arsenal. That's all. Feel free to
\00:09:19.811 --> 00:09:23.992 continue to use SMTP to go as well. These are just tools for
\00:09:23.992 --> 00:09:27.556 us to to have and use for appropriate scenarios so.
\00:09:28.396 --> 00:09:30.696 Good job. Thanks man. Appreciate it.
\00:09:29.956 --> 00:09:30.336 That.
\00:09:32.516 --> 00:09:35.286 And also you have a nice looking chain, the end.
\00:09:35.766 --> 00:09:36.376 Thanks man.
\00:09:37.906 --> 00:09:39.976 It's not a gold chain, but man.
\00:09:40.796 --> 00:09:44.250 I like it. Alright. Well, I'm gonna jump. I have to do some
\00:09:41.606 --> 00:09:42.636 But it'll do.
\00:09:44.250 --> 00:09:47.819 discovery with seem MC on the next six months of work and get
\00:09:47.819 --> 00:09:50.696 that all worked out and they're waiting on me so.
\00:09:50.816 --> 00:09:54.361 Yes, the room today. Thank you, Sir. And over. Yeah, you too.
\00:09:51.506 --> 00:09:55.037 Hope you guys have a great weekend. Thank you all for all
\00:09:54.361 --> 00:09:57.276 Thank you. Thank you. And over to you, Sir Murphy.
\00:09:55.037 --> 00:09:57.106 you do. Bye guys. Cheers. See ya.
\00:09:59.476 --> 00:10:00.686 Awesome. Thanks. Thanks Ben.
\00:10:02.186 --> 00:10:05.685 Alright, cool. So I think connect can break out and then
\00:10:05.685 --> 00:10:09.736 front end can break out and then we'll keep the back Enders here.
\00:10:15.596 --> 00:10:18.035 And Justin, would you mind spending up something for the
\00:10:18.035 --> 00:10:18.676 front end team?
\00:10:19.426 --> 00:10:22.456 Yep, can do. I'll make the room.
\00:10:19.676 --> 00:10:21.236 Program awesome.
\00:10:23.566 --> 00:10:24.516 Thank you, Sir.
\00:10:31.766 --> 00:10:32.476 Thanks everybody.
\00:10:33.166 --> 00:10:36.504 And don't you think it'd be OK for me and Alex to pick back up
\00:10:36.504 --> 00:10:38.146 with his new page on the admin?
\00:10:38.976 --> 00:10:39.746 Hell yeah.
\00:10:40.806 --> 00:10:43.742 We'll just go back to that same room. Well, we'll make a new one
\00:10:43.176 --> 00:10:43.936 It's perfect.
\00:10:43.506 --> 00:10:43.996 Perfect.
\00:10:43.742 --> 00:10:46.226 that has you in it. If you want to come cool right on.
\00:10:45.976 --> 00:10:46.956 Perfect.
\00:10:50.666 --> 00:10:52.556 What are we doing for back end today?
\00:10:56.586 --> 00:10:59.236 Yeah, there wasn't really anything specific planned.
\00:11:00.956 --> 00:11:02.156 Anything you want to talk about?
\00:11:03.216 --> 00:11:05.076 There's always things I can talk about, but.
\00:11:06.816 --> 00:11:09.126 The real question is, is there anything I can talk about for?
\00:11:10.646 --> 00:11:11.156 An hour.
\00:11:11.736 --> 00:11:15.896 Well, I wonder if any backhanders are interested in.
\00:11:17.256 --> 00:11:20.518 In react, from your, from your perspective, now you've worked
\00:11:20.518 --> 00:11:23.516 on a little bit like a back end or perspective on react.
\00:11:24.826 --> 00:11:28.074 They could talk about this whole Redux thing. I've been working
\00:11:28.074 --> 00:11:28.226 on.
\00:11:29.076 --> 00:11:31.286 I think, yeah, I think there'll be some value there.
\00:11:31.606 --> 00:11:34.633 Let's let's use that as a backup. Uh, if if anyone has any
\00:11:34.633 --> 00:11:37.866 questions on other things first, only because Brendan, I don't
\00:11:37.866 --> 00:11:39.866 know if you're fully done with it yet.
\00:11:41.396 --> 00:11:44.903 The site works mostly there's some, there's some bugs and
\00:11:43.956 --> 00:11:44.376 Well, sure.
\00:11:44.903 --> 00:11:45.326 fixing.
\00:11:45.676 --> 00:11:46.426 Yeah, no worries.
\00:11:46.556 --> 00:11:49.866 But, but yeah, not quite 100% done yet.
\00:11:50.126 --> 00:11:53.126 Yeah, I mean, that's fine if if there's nothing else, I think
\00:11:53.126 --> 00:11:56.175 that that's good. Does A is a good overview, but I think maybe
\00:11:56.175 --> 00:11:59.223 just general how how react works as through the eyes of a back
\00:11:59.223 --> 00:11:59.416 end.
\00:12:00.586 --> 00:12:03.283 Or, but first, probably any questions from Beck Enders on
\00:12:03.283 --> 00:12:04.166 anything? Probably.
\00:12:06.886 --> 00:12:07.956 That sounds good.
\00:12:19.296 --> 00:12:20.606 10 brents.
\00:12:22.556 --> 00:12:27.180 Anything you guys are working on that you want? Want some help
\00:12:27.180 --> 00:12:27.546 with?
\00:12:29.746 --> 00:12:31.636 I'm not. That's not right off either.
\00:12:33.036 --> 00:12:35.946 Don't anybody anybody at all.
\00:12:43.446 --> 00:12:45.056 Ohly, I mean the only thing that I.
\00:12:46.116 --> 00:12:49.313 But I've got office hours scheduled with you for the last
\00:12:49.313 --> 00:12:50.746 six service modifications.
\00:12:53.186 --> 00:12:56.456 But that's really the only thing that comes to mind or something.
\00:12:55.266 --> 00:12:55.786 Yeah, yeah.
\00:12:59.046 --> 00:13:00.836 Wouldn't be a bad one. TMK which got.
\00:13:03.296 --> 00:13:05.928 I was just gonna say that I'm probably having a brain fart.
\00:13:05.928 --> 00:13:07.726 Everybody done this couple of weeks ago.
\00:13:08.436 --> 00:13:09.246 But.
\00:13:10.476 --> 00:13:13.596 I think everyone soil, so it could do like a sweep on the.
\00:13:14.436 --> 00:13:17.336 Locking down endpoints and the you know difference between the
\00:13:17.336 --> 00:13:20.328 used it and then Tums versus the permissions type stuff. As long
\00:13:20.328 --> 00:13:21.386 as everyone knows that.
\00:13:22.916 --> 00:13:23.926 Think we're good to go.
\00:13:25.156 --> 00:13:27.226 I think we we covered that.
\00:13:28.226 --> 00:13:29.656 Just only a couple weeks ago.
\00:13:30.006 --> 00:13:30.326 Yeah, yeah.
\00:13:30.716 --> 00:13:34.884 Umm. And it was recorded. So it's there's there's record of
\00:13:34.884 --> 00:13:35.786 it somewhere.
\00:13:37.076 --> 00:13:38.406 Then I have hope.
\00:13:37.146 --> 00:13:37.736 We need to.
\00:13:47.816 --> 00:13:48.576 Right.
\00:13:54.986 --> 00:13:55.566 That's something.
\00:13:56.846 --> 00:13:58.876 Lying to make this not have errors.
\00:14:14.556 --> 00:14:15.646 All right, well.
\00:14:20.166 --> 00:14:24.244 If nobody has anything specific, so we've got office hours for
\00:14:24.244 --> 00:14:28.258 the elastic search thing, and I'm guessing it's like specific
\00:14:28.258 --> 00:14:29.746 questions around stuff.
\00:14:30.746 --> 00:14:32.116 Yeah, yeah, yeah.
\00:14:47.916 --> 00:14:49.496 All right, well.
\00:14:51.646 --> 00:14:53.136 It's not have been a good one to cover with.
\00:14:54.126 --> 00:14:54.676 Every one.
\00:14:55.966 --> 00:14:58.956 So I've got, you know, there's probably things I don't know.
\00:15:00.146 --> 00:15:03.351 There's definitely things I don't know. I don't even say
\00:15:03.351 --> 00:15:03.856 probably.
\00:15:05.776 --> 00:15:06.976 But I guess I'll go ahead and.
\00:15:08.876 --> 00:15:11.166 Share my screen.
\00:15:12.966 --> 00:15:13.476 So.
\00:15:15.646 --> 00:15:19.866 I have been working on some updates to.
\00:15:20.886 --> 00:15:23.576 Uh, react and along the way I've been.
\00:15:24.806 --> 00:15:25.916 Learning react.
\00:15:26.856 --> 00:15:27.536 Go figure.
\00:15:28.826 --> 00:15:33.307 And so, yeah, I think there's probably a good amount of value
\00:15:33.307 --> 00:15:33.596 and.
\00:15:34.506 --> 00:15:36.406 Walking people through stuff.
\00:15:37.176 --> 00:15:37.626 Me.
\00:15:39.126 --> 00:15:40.036 Collapsed.
\00:15:43.316 --> 00:15:45.116 Uh, pretend there's not.
\00:15:46.456 --> 00:15:48.106 A ton of modified files.
\00:15:50.446 --> 00:15:54.306 I'm working on it but anyway so.
\00:15:58.376 --> 00:16:01.263 I'm trying to think of how to start this. Where do I? Where do
\00:16:01.263 --> 00:16:01.766 I commence?
\00:16:05.716 --> 00:16:09.616 Uh, alright so much, much like.
\00:16:11.136 --> 00:16:16.149 Much like the back end, reactive splits things out into pieces.
\00:16:16.149 --> 00:16:19.046 Individual parts that can be reused.
\00:16:20.036 --> 00:16:22.656 And so we find a good like.
\00:16:23.456 --> 00:16:27.236 Concise example something something relatively small.
\00:16:29.896 --> 00:16:32.186 But I keep accidentally opening the same file.
\00:16:33.666 --> 00:16:37.216 Ohh there should be something cool and useful in here.
\00:16:38.746 --> 00:16:41.066 Well, that's decent enough so.
\00:16:42.486 --> 00:16:46.788 For our specific stuff and and for react in general, like
\00:16:46.788 --> 00:16:51.090 modern React components are defined as functions and it's
\00:16:51.090 --> 00:16:53.686 basically a function that returns.
\00:16:54.816 --> 00:16:57.786 What looks like HTML, they call it JSX.
\00:16:58.446 --> 00:17:01.826 Umm. And you can do.
\00:17:02.776 --> 00:17:05.586 Uh, logic that determines exactly how this.
\00:17:06.466 --> 00:17:09.056 How this return value comes out same as any old function?
\00:17:11.756 --> 00:17:16.208 And the neat thing about them is that the function style
\00:17:16.208 --> 00:17:20.816 components can also make use of hooks, so these are hooks.
\00:17:21.626 --> 00:17:26.075 Umm. And effectively, what hooks do is you can. There's default
\00:17:26.075 --> 00:17:30.037 built-in hooks for stuff like component state, so that's
\00:17:30.037 --> 00:17:34.277 things that whenever the value updates, it will trigger that
\00:17:34.277 --> 00:17:35.806 component to rerender.
\00:17:37.206 --> 00:17:39.336 There's other things that are similar to that.
\00:17:39.976 --> 00:17:43.465 Umm, with uh, there's a hook called use effect which will run
\00:17:43.465 --> 00:17:46.504 every time it's list of dependencies changes. So it's
\00:17:46.504 --> 00:17:49.486 basically just like a a watch for a value, so I can.
\00:17:51.756 --> 00:17:56.293 I can have this function run every time SEF config changes
\00:17:56.293 --> 00:17:57.446 and I can just.
\00:17:59.536 --> 00:18:03.031 That can take changed obviously Jeff configs not gonna be
\00:18:03.031 --> 00:18:04.236 changing very often.
\00:18:04.976 --> 00:18:08.116 Uh, at least not all the page is already loaded, but that's you
\00:18:08.116 --> 00:18:11.108 get the kind of idea is that this is just a function you can
\00:18:11.108 --> 00:18:14.247 run whenever something in here changes and this can be multiple
\00:18:14.247 --> 00:18:15.326 things, this could be.
\00:18:16.046 --> 00:18:18.156 Suh config or this teeth thing?
\00:18:20.156 --> 00:18:23.526 Or the changed and you can react to those changes.
\00:18:24.566 --> 00:18:25.576 No unintended.
\00:18:30.816 --> 00:18:34.531 So anyway, the the fun thing with it too is that you can
\00:18:34.531 --> 00:18:38.766 create custom hooks, for example this custom hook use SEF config
\00:18:38.766 --> 00:18:42.350 and it gets even more interesting because custom hooks
\00:18:42.350 --> 00:18:44.956 can use more hooks and so you can have.
\00:18:45.886 --> 00:18:48.136 Reusable pieces of complex data.
\00:18:48.846 --> 00:18:49.596 Umm.
\00:18:50.936 --> 00:18:55.024 And the entire use for it is somebody just calls this. So for
\00:18:55.024 --> 00:18:59.111 this example, the custom use Jeff config hook that I made. It
\00:18:59.111 --> 00:19:03.265 reads the Jeff config value out of global state which is Redux
\00:19:03.265 --> 00:19:07.352 and then it has a use effect for every time that changes. Use
\00:19:07.352 --> 00:19:11.308 effects also run the first time the component is mounted or
\00:19:11.308 --> 00:19:14.406 renders. So this will run when the page loads.
\00:19:15.486 --> 00:19:19.086 Effectively, or when that first component loads, and if the SEV
\00:19:19.086 --> 00:19:22.799 config is null, then it reads it out of the document since that's
\00:19:22.799 --> 00:19:24.036 how it's being stored.
\00:19:24.886 --> 00:19:26.986 I think I have this open over here, yeah.
\00:19:29.606 --> 00:19:33.366 Fresh stuff from react very bottom this file document dot
\00:19:33.366 --> 00:19:35.116 set config equals settings.
\00:19:36.416 --> 00:19:40.634 This reads it out and the really interesting thing about it is
\00:19:40.634 --> 00:19:44.718 that this dispatch is the. This uses dispatches Redux to set
\00:19:44.718 --> 00:19:49.003 that self config in global state and because this is using that
\00:19:49.003 --> 00:19:51.546 from global state that triggers this.
\00:19:52.536 --> 00:19:55.852 Use this this hook to quote UN quote rerender. This book is
\00:19:55.852 --> 00:19:59.223 data only, it's not actually rendering anything, but it will
\00:19:59.223 --> 00:20:02.539 rerun this hook which returns a different value because now
\00:20:02.539 --> 00:20:06.186 stuff config isn't null anymore. This will set it to be not null.
\00:20:07.346 --> 00:20:10.610 And the really neat thing about that is when this hook renders
\00:20:10.610 --> 00:20:13.511 or reruns anything that references, this hook will also
\00:20:13.511 --> 00:20:16.256 rerender, so this will automatically get the updated
\00:20:16.256 --> 00:20:19.520 SEF config. You don't have to do any kind of broadcasts or any
\00:20:19.520 --> 00:20:22.731 kind of manual listening for things. The entire functionality
\00:20:22.731 --> 00:20:25.943 for. If you need to use Jeff config is use SEF config and the
\00:20:25.943 --> 00:20:29.154 first component that loads that needs it will be the one that
\00:20:29.154 --> 00:20:31.226 resolves it, sets it in the goal state.
\00:20:32.986 --> 00:20:33.396 So.
\00:20:36.186 --> 00:20:39.416 That's part of the improvements I've been working on with Redux,
\00:20:39.416 --> 00:20:42.547 is that previously there was a lot more manual effort involved
\00:20:42.547 --> 00:20:45.528 in using Jeff config or using the address book or using the
\00:20:45.528 --> 00:20:48.510 wallet or whatever it is, and now it's a lot simpler if you
\00:20:48.510 --> 00:20:50.596 need to use the shopping cart you can do.
\00:20:51.606 --> 00:20:53.156 Uh, use cart.
\00:20:55.946 --> 00:21:00.557 Service string stuff carts dot types dot cart and now you have
\00:21:00.557 --> 00:21:05.314 access to the shopping cart and every time the cart updates your
\00:21:05.314 --> 00:21:09.046 component will rerender automatically and you can.
\00:21:09.686 --> 00:21:10.216 React.
\00:21:10.956 --> 00:21:15.759 Uh-huh. Uh to anything that that changes in that component in
\00:21:15.759 --> 00:21:16.766 that cart so.
\00:21:18.506 --> 00:21:21.830 Same deal with like wallet. There's a use wallet hook.
\00:21:21.830 --> 00:21:25.516 There's a use address book. Uh. Let's see. Use current user.
\00:21:26.266 --> 00:21:27.366 Use current account.
\00:21:31.246 --> 00:21:34.479 Presently there's a use signalr, but I'm going to be getting rid
\00:21:34.479 --> 00:21:36.816 of that because there's a better way to do it.
\00:21:38.706 --> 00:21:40.536 Actually, I think I might have already gotten rid of it.
\00:21:42.466 --> 00:21:44.466 But that's mostly relevant to bidding stuff.
\00:21:47.046 --> 00:21:50.834 Yeah. So this one just has it initializes the connection. I
\00:21:50.834 --> 00:21:54.747 need to get rid of. We're not going to actually store Signalr
\00:21:54.747 --> 00:21:58.787 hub connections in global state because I learned that that's a
\00:21:58.787 --> 00:22:02.827 no no. So we just won't do that. But this will doesn't store in
\00:22:02.827 --> 00:22:05.036 global state each individual hook.
\00:22:06.356 --> 00:22:10.081 Maintains its own instance of the connection, but the
\00:22:10.081 --> 00:22:13.874 Microsoft Signalr package utilizes the same underlying
\00:22:13.874 --> 00:22:18.082 connection for every instance that you initialize, so that's
\00:22:18.082 --> 00:22:18.426 good.
\00:22:25.176 --> 00:22:25.866 All right.
\00:22:26.976 --> 00:22:32.113 So yeah, it just gets, you know, this is a hook calling a hook
\00:22:32.113 --> 00:22:36.596 that calls more hooks. So it's hooks all the way down.
\00:22:37.606 --> 00:22:38.256 Or whatever.
\00:22:39.506 --> 00:22:40.696 But anyway.
\00:22:44.386 --> 00:22:47.331 A lot of the improvement that I've been working on right now
\00:22:47.331 --> 00:22:50.227 and and the the thing that kind of spurred me to learn more
\00:22:50.227 --> 00:22:50.516 about.
\00:22:51.526 --> 00:22:52.036 Uh.
\00:22:53.236 --> 00:22:54.156 About uh.
\00:22:57.196 --> 00:23:01.726 React and Redux and everything is I'm working on.
\00:23:02.256 --> 00:23:06.815 Umm, basically a a component that allows you to guard any
\00:23:06.815 --> 00:23:11.689 other component by requiring a role or requiring a permission
\00:23:11.689 --> 00:23:13.496 to view that component.
\00:23:14.246 --> 00:23:16.886 Umm and functionally basically is just.
\00:23:20.486 --> 00:23:24.466 See here. We could just wrap this image with fall back and.
\00:23:26.386 --> 00:23:29.126 Come on autocomplete help me out here.
\00:23:35.746 --> 00:23:36.546 It's not finding it.
\00:23:44.476 --> 00:23:46.446 OK, sense source shared all right.
\00:23:58.796 --> 00:24:03.784 I didn't want to pick that up, but it's fine. OK, so then the
\00:24:03.784 --> 00:24:08.612 auth guard is a component that you can put other components
\00:24:08.612 --> 00:24:09.496 inside and.
\00:24:11.556 --> 00:24:15.546 Uh, by default, just an empty Oscar doesn't do anything.
\00:24:16.086 --> 00:24:20.294 Umm, but I can say requires auth equals true and now this
\00:24:20.294 --> 00:24:23.776 component will not render unless I'm logged in.
\00:24:26.026 --> 00:24:28.396 And then I can also do something like.
\00:24:31.226 --> 00:24:33.176 Fall back equals.
\00:24:35.396 --> 00:24:38.096 You log in to you this.
\00:24:39.246 --> 00:24:43.074 Umm so I can have it render a fall back if the condition
\00:24:43.074 --> 00:24:47.171 fails. It can also be a more complex condition like requires
\00:24:47.171 --> 00:24:47.506 role.
\00:24:48.496 --> 00:24:53.196 And that role would be like, you know, Steph user, whatever or
\00:24:53.196 --> 00:24:54.986 Stef stored ministrator.
\00:24:56.986 --> 00:24:58.516 Or requiring a permission.
\00:25:02.466 --> 00:25:04.336 Product stop product data update.
\00:25:06.346 --> 00:25:09.400 Or something, right, and anything that's inside of this
\00:25:09.400 --> 00:25:12.671 component. Any children of this component won't be rendered
\00:25:12.671 --> 00:25:13.706 unless this passes.
\00:25:14.326 --> 00:25:18.136 Umm. And the reason that I started going down this hole.
\00:25:19.236 --> 00:25:20.756 Uh redux?
\00:25:22.566 --> 00:25:24.166 Process was because.
\00:25:25.126 --> 00:25:26.796 I was having a lot of trouble.
\00:25:28.646 --> 00:25:32.996 Uh, getting that to behave the way that I wanted it to.
\00:25:36.486 --> 00:25:39.156 And so that was kind of the thing that spurred me to go.
\00:25:40.696 --> 00:25:41.806 Beat up redux.
\00:25:45.926 --> 00:25:46.536 Umm.
\00:25:49.826 --> 00:25:50.416 Well.
\00:25:53.616 --> 00:25:54.366 I don't know how much.
\00:25:55.306 --> 00:25:57.981 I don't know what else to cover. Does anybody have questions
\00:25:57.981 --> 00:26:00.656 about react? Again, there's probably stuff I don't know, but
\00:26:00.656 --> 00:26:02.936 I'm I'm glad to try my hand at answering questions.
\00:26:14.846 --> 00:26:16.136 Oh yeah, this is gone now.
\00:26:18.766 --> 00:26:19.326 To.
\00:26:19.036 --> 00:26:21.506 Have there any questions you think we should ask?
\00:26:24.676 --> 00:26:25.416 I don't know.
\00:26:27.456 --> 00:26:30.990 I don't know what everyone's familiarity or comfort with it
\00:26:30.990 --> 00:26:31.166 is.
\00:26:43.866 --> 00:26:45.256 Should not do.
\00:26:46.006 --> 00:26:48.246 Auths state this should do.
\00:26:57.936 --> 00:26:58.436 You will.
\00:27:00.936 --> 00:27:03.516 And we can do is.
\00:27:15.386 --> 00:27:17.616 And I was it's gonna complain about this.
\00:27:27.696 --> 00:27:31.136 Yeah, OK, now the auth guard should actually be functional.
\00:27:36.386 --> 00:27:37.676 It's a number of things I'm still.
\00:27:40.386 --> 00:27:45.179 Trying to get working with the the change to the new Redux
\00:27:45.179 --> 00:27:45.666 stuff.
\00:27:47.846 --> 00:27:48.656 Umm.
\00:27:51.566 --> 00:27:53.226 Namely, if I go to the catalog.
\00:27:54.896 --> 00:27:57.116 Anything that is a lot is.
\00:27:58.446 --> 00:27:58.826 You know.
\00:27:59.856 --> 00:28:00.836 Looking a little bear.
\00:28:02.466 --> 00:28:04.805 It's missing some stuff. This one's missing the header
\00:28:04.805 --> 00:28:06.676 entirely. This one at least has the header.
\00:28:07.656 --> 00:28:08.036 But.
\00:28:12.176 --> 00:28:13.076 If I can figure that out.
\00:28:15.476 --> 00:28:19.466 Let's product card bidding widget, yeah.
\00:28:21.646 --> 00:28:21.876 OK.
\00:28:25.116 --> 00:28:26.006 User.
\00:28:29.226 --> 00:28:30.636 The references to this guy.
\00:28:37.276 --> 00:28:39.596 Not a lot or not bidding factory.
\00:28:42.036 --> 00:28:43.246 And it returns null.
\00:28:45.116 --> 00:28:47.746 And that seems to be the only early out.
\00:28:48.696 --> 00:28:52.014 So either the lot of the bidding factor, he never actually get
\00:28:52.014 --> 00:28:52.646 initialized.
\00:28:53.546 --> 00:28:54.826 What's going on in here?
\00:29:03.706 --> 00:29:04.086 Hmm.
\00:29:05.496 --> 00:29:06.586 This seems relevant.
\00:29:30.126 --> 00:29:32.466 Those components mounted after.
\00:29:36.726 --> 00:29:38.196 Connection was null.
\00:29:39.226 --> 00:29:41.931 No. And then you can see the signal R connection gets
\00:29:41.931 --> 00:29:44.686 established, which then sets it and now it's not null.
\00:29:45.656 --> 00:29:48.206 OK. So do we ever get past this then?
\00:29:51.076 --> 00:29:53.126 So now we should only see this up with once.
\00:29:53.746 --> 00:29:57.669 On that was potentially more than once per hook. OK, so it
\00:29:57.669 --> 00:30:01.856 got there, which means it should have initialized the factory.
\00:30:05.676 --> 00:30:09.126 Should set the instance which is state.
\00:30:11.936 --> 00:30:12.936 That gets returned.
\00:30:14.826 --> 00:30:18.360 And the change some of this around to use a new way, that's
\00:30:18.360 --> 00:30:19.066 better, but.
\00:30:26.356 --> 00:30:27.286 Ah.
\00:30:29.466 --> 00:30:29.946 All right.
\00:30:31.316 --> 00:30:32.606 So that's not the problem.
\00:30:46.146 --> 00:30:47.776 Which those the problem.
\00:30:56.946 --> 00:31:00.476 It would be both of them up pair.
\00:31:05.016 --> 00:31:05.856 Umm.
\00:31:09.446 --> 00:31:11.556 Now, why would that happen?
\00:31:36.266 --> 00:31:37.516 Hmm.
\00:31:40.096 --> 00:31:41.246 We have this guy.
\00:31:44.336 --> 00:31:45.676 Once again, we'll go look at that.
\00:31:47.576 --> 00:31:48.866 I aboleth closely.
\00:31:59.926 --> 00:32:02.796 Actually, let's do. Yeah, actually that's fine.
\00:32:05.216 --> 00:32:07.556 Distance from bidding factory.
\00:32:11.366 --> 00:32:12.876 And then we can do it over here.
\00:32:14.356 --> 00:32:14.726 Ah.
\00:32:15.706 --> 00:32:16.836 That's from.
\00:32:18.356 --> 00:32:19.846 Uh, what's that thing called?
\00:32:21.346 --> 00:32:22.126 Billing.
\00:32:23.446 --> 00:32:25.626 Widget bidding.
\00:32:40.396 --> 00:32:43.293 OK, so the instance from the bidding factory gets set, but
\00:32:43.293 --> 00:32:45.306 that hooks not triggering a rerender of.
\00:32:46.216 --> 00:32:47.566 The component that it lives in.
\00:32:55.846 --> 00:32:56.286 Umm.
\00:33:01.086 --> 00:33:03.946 In fact, it seems like this never rendered at all.
\00:33:05.026 --> 00:33:06.516 Which begs the question.
\00:33:13.596 --> 00:33:16.934 OK, so factoring all factoring, all instance from bidding
\00:33:16.934 --> 00:33:17.336 widget?
\00:33:18.436 --> 00:33:20.226 Instance from bidding widget is no.
\00:33:22.626 --> 00:33:24.936 And that's the last time that that ever ran.
\00:33:26.156 --> 00:33:27.816 Last time the component ever rendered.
\00:33:32.416 --> 00:33:33.146 Set.
\00:33:34.326 --> 00:33:35.466 This thing over here.
\00:33:41.776 --> 00:33:42.136 Hmm.
\00:33:43.496 --> 00:33:44.246 I would it not.
\00:33:48.056 --> 00:33:49.606 That's that down.
\00:34:00.096 --> 00:34:01.166 Let's try this then.
\00:34:23.166 --> 00:34:27.876 Restructure this thing to do something really cool.
\00:34:32.096 --> 00:34:34.666 Returning the implementation.
\00:34:36.846 --> 00:34:39.376 Ohh the interface.
\00:34:40.216 --> 00:34:41.666 In the return line.
\00:34:56.536 --> 00:34:56.866 OK.
\00:34:58.336 --> 00:35:00.196 And I gotta get rid of some this dots.
\00:35:06.136 --> 00:35:08.926 I got semicolons and need to be replaced with commas on these
\00:35:08.926 --> 00:35:09.106 two.
\00:35:10.626 --> 00:35:11.516 I think is why it's.
\00:35:12.906 --> 00:35:16.136 Finding about the this start, that is actually technically.
\00:35:18.416 --> 00:35:19.696 Not a problem.
\00:35:33.306 --> 00:35:33.526 Yeah.
\00:35:56.396 --> 00:35:59.506 Object is possibly undefined.
\00:36:00.546 --> 00:36:02.516 Am I not defining it right now?
\00:36:05.316 --> 00:36:08.244 I've done this exact thing in other places and it didn't
\00:36:08.244 --> 00:36:08.706 complain.
\00:36:10.916 --> 00:36:12.706 But that's the beauty of life.
\00:36:14.766 --> 00:36:15.356 It's pain.
\00:36:16.386 --> 00:36:17.036 Or something.
\00:36:23.716 --> 00:36:24.776 It's complaining about that.
\00:36:34.276 --> 00:36:36.826 Somewhere I'm doing this exact same thing.
\00:36:38.936 --> 00:36:40.216 And one of these other hooks.
\00:36:52.616 --> 00:36:53.566 Maybe I'm not.
\00:36:56.706 --> 00:36:57.536 Golly Gee.
\00:37:00.036 --> 00:37:01.026 Ain't that just?
\00:37:03.556 --> 00:37:05.346 Or maybe it's because this is here and I'm stupid.
\00:37:15.566 --> 00:37:16.426 Oh my goodness.
\00:37:18.626 --> 00:37:19.436 I'm ignoring that.
\00:37:28.256 --> 00:37:28.686 Oops.
\00:37:35.906 --> 00:37:37.866 Unexpected this.
\00:37:54.876 --> 00:37:55.766 That's what I had to do with that.
\00:37:59.846 --> 00:38:00.126 But.
\00:38:00.936 --> 00:38:01.326 Yeah.
\00:38:03.086 --> 00:38:05.016 Something like that probably works.
\00:38:12.826 --> 00:38:13.726 OK, there we go.
\00:38:14.546 --> 00:38:15.426 See if that works.
\00:38:34.566 --> 00:38:37.556 I wonder where the pricing call home. OK, so.
\00:38:40.626 --> 00:38:41.456 Still.
\00:38:43.186 --> 00:38:44.816 Still not getting anything here.
\00:39:06.026 --> 00:39:09.260 That it will actually return a result then obviously it does
\00:39:09.260 --> 00:39:12.546 cause signalr gets initialized. Yes, it does return a result.
\00:39:32.676 --> 00:39:34.326 Never gets it in here.
\00:39:35.106 --> 00:39:36.336 The whole point of the hook.
\00:39:37.546 --> 00:39:39.006 And it's simply isn't working.
\00:39:43.136 --> 00:39:43.976 That's pretty annoying.
\00:39:52.486 --> 00:39:53.696 Come on, data.
\00:39:56.136 --> 00:39:57.266 Why would this not work?
\00:40:04.216 --> 00:40:05.986 This must be fascinating to watch.
\00:40:11.336 --> 00:40:12.596 It's got good commentary.
\00:40:13.756 --> 00:40:14.386 I'm trying.
\00:40:15.476 --> 00:40:16.576 It's a dry subject.
\00:40:23.626 --> 00:40:25.376 You're doing good, man. I'm on the edge of my seat.
\00:40:26.746 --> 00:40:30.606 No, that's, I'm, I'm glad. I'm glad. I'm glad someone is.
\00:40:31.356 --> 00:40:33.046 Alright, so is this ever running then?
\00:40:34.706 --> 00:40:35.306 Hello.
\00:40:37.696 --> 00:40:38.496 Tried and true.
\00:40:39.266 --> 00:40:42.733 As you can see, the one thing I haven't learned about react yet
\00:40:42.733 --> 00:40:45.386 is how to debug without console logs everywhere.
\00:40:48.146 --> 00:40:49.876 OK, so this ran twice.
\00:40:48.396 --> 00:40:48.816 Ohh.
\00:40:50.386 --> 00:40:54.256 Can't you just go into sources and slap some break points in
\00:40:54.256 --> 00:40:54.636 there?
\00:40:55.416 --> 00:40:57.786 Maybe I never knew if this worked or not.
\00:40:56.596 --> 00:40:57.506 Yeah, just.
\00:40:58.246 --> 00:41:01.056 Yeah, that's what she. Yeah, it sure does work.
\00:40:58.636 --> 00:40:59.196 It did.
\00:41:00.566 --> 00:41:03.860 I don't know. OK, well, that's good. How do I get into a
\00:41:03.860 --> 00:41:06.576 specific? Apparently I've been in here before.
\00:41:08.916 --> 00:41:09.776 That's a lot of files.
\00:41:10.236 --> 00:41:12.426 So you can see.
\00:41:10.996 --> 00:41:12.576 I think it in here.
\00:41:14.166 --> 00:41:17.448 I think you can search for like a method call or something,
\00:41:17.448 --> 00:41:17.776 right?
\00:41:18.726 --> 00:41:19.216 Tristan.
\00:41:20.526 --> 00:41:21.516 This looks like a winner.
\00:41:22.956 --> 00:41:23.246 Well.
\00:41:23.216 --> 00:41:24.846 Yeah.
\00:41:24.156 --> 00:41:25.316 Maybe, maybe not.
\00:41:26.376 --> 00:41:29.190 I think this might be only the cat the components are actually
\00:41:29.190 --> 00:41:29.726 on the page.
\00:41:30.376 --> 00:41:33.383 Or about the, I mean you can click one of them, just see
\00:41:33.383 --> 00:41:34.226 what's in there.
\00:41:35.906 --> 00:41:37.206 What are you trying to debug?
\00:41:38.526 --> 00:41:41.356 Uh, very annoying issue.
\00:41:42.216 --> 00:41:45.507 So I have a hook that returns a value and I have asserted that
\00:41:45.507 --> 00:41:47.126 it definitely returns a result.
\00:41:48.506 --> 00:41:49.236 Umm.
\00:41:48.866 --> 00:41:52.323 Use bidding factory and then where's use bidding factory
\00:41:50.856 --> 00:41:51.616 And.
\00:41:52.323 --> 00:41:52.626 used?
\00:41:53.076 --> 00:41:56.299 Right here in this component and I can see that this component
\00:41:56.299 --> 00:41:59.215 renders when other things change, but not when this hook
\00:41:58.366 --> 00:41:58.836 Uh-huh.
\00:41:59.215 --> 00:42:02.386 returns a new value. It does not trigger this to to rerender.
\00:42:03.256 --> 00:42:04.166 And this is.
\00:42:04.436 --> 00:42:04.766 Alright.
\00:42:05.196 --> 00:42:07.486 A hook like any other, it's nothing special.
\00:42:09.376 --> 00:42:12.866 So I have no idea why it would not be triggering that rerender.
\00:42:09.916 --> 00:42:11.146 So I think.
\00:42:12.886 --> 00:42:15.747 The file you had opened there maybe. Just make sure it gets
\00:42:15.747 --> 00:42:18.751 hit cause the the original one you had open looked like what I
\00:42:18.751 --> 00:42:21.708 would normally see when I'm it's been forever since I've been
\00:42:21.708 --> 00:42:22.756 messing with react so.
\00:42:22.946 --> 00:42:25.990 Yeah. So this you talk about this, this one looks like normal
\00:42:25.990 --> 00:42:27.266 like it's just a standard.
\00:42:27.616 --> 00:42:28.216 Yeah.
\00:42:27.926 --> 00:42:30.705 Pretty standard hook, right this file. This is definitely being
\00:42:30.705 --> 00:42:33.310 rendered because I'm seeing it output instance from bidding
\00:42:32.936 --> 00:42:33.216 Yeah.
\00:42:33.310 --> 00:42:34.786 widget and it's just always null.
\00:42:37.556 --> 00:42:38.776 I mean, I guess you could always like.
\00:42:40.056 --> 00:42:43.176 In the browser it had it had already had like the catalog.
\00:42:44.306 --> 00:42:47.190 Uh TSX file open. You can always like slap a breakpoint in there
\00:42:47.190 --> 00:42:48.876 and step into something I don't know.
\00:42:52.256 --> 00:42:55.016 Like under man? Or was it?
\00:42:55.736 --> 00:42:58.574 And I guess you have. What what's that like? If you click
\00:42:58.574 --> 00:43:01.461 the catalog format, blah blah blah. Is that like an actual
\00:43:01.461 --> 00:43:02.586 file? Can't really see.
\00:43:02.346 --> 00:43:05.375 That's the that's the page that's like the actual physical
\00:43:04.406 --> 00:43:05.336 That's the page.
\00:43:05.375 --> 00:43:08.506 page that's coming back from DNN. These are, I would assume,
\00:43:08.506 --> 00:43:09.276 be aware of my.
\00:43:10.236 --> 00:43:12.116 Components come from that being said.
\00:43:11.396 --> 00:43:12.816 Ohh yeah, build source.
\00:43:13.446 --> 00:43:13.906 Yeah.
\00:43:16.056 --> 00:43:19.406 Doesn't feel like everything's here, and I don't see this
\00:43:19.406 --> 00:43:21.426 specific component that's missing.
\00:43:23.316 --> 00:43:26.406 It's like this is not, I mean it's definitely not all of the.
\00:43:27.396 --> 00:43:28.786 Where's this even get this from?
\00:43:33.116 --> 00:43:33.996 File system.
\00:43:35.026 --> 00:43:37.196 Ah, this looks like a win.
\00:43:38.676 --> 00:43:39.586 See here.
\00:43:39.036 --> 00:43:41.703 Yeah, I guess just try slapping on break point and something you
\00:43:41.703 --> 00:43:42.646 know that gets hit and.
\00:43:43.626 --> 00:43:46.146 See what happens, because I think you can just do that.
\00:43:47.826 --> 00:43:48.176 Yeah.
\00:43:52.536 --> 00:43:53.296 Ah.
\00:43:53.686 --> 00:43:57.296 OK, so there's a result. It's clearly not null.
\00:44:00.746 --> 00:44:03.365 It's a few times because there's more than one thing using it,
\00:44:03.365 --> 00:44:03.946 which is fine.
\00:44:05.646 --> 00:44:10.744 Alright, so then if I go into catalog, I think it's controls
\00:44:10.744 --> 00:44:12.916 product card controls, no?
\00:44:15.676 --> 00:44:16.416 Use.
\00:44:17.326 --> 00:44:18.876 Product card widgets.
\00:44:19.786 --> 00:44:21.656 Product card bidding, which it there we go.
\00:44:32.996 --> 00:44:34.576 Getting factory is null.
\00:44:36.686 --> 00:44:40.136 Use bidding factor. I guess I don't know.
\00:44:42.216 --> 00:44:43.116 Still null.
\00:44:44.996 --> 00:44:47.180 Now we're returning a result from here, which means it
\00:44:47.180 --> 00:44:49.562 shouldn't be know anymore, but it doesn't trigger that. Use
\00:44:49.562 --> 00:44:51.626 effect or trigger the component to rerender at all.
\00:45:02.126 --> 00:45:02.676 Hmm.
\00:45:32.016 --> 00:45:32.676 I.
\00:45:34.516 --> 00:45:38.306 Knowingly break it, but see if it breaks in a different way.
\00:45:42.626 --> 00:45:43.966 Immediately return a result.
\00:45:49.506 --> 00:45:50.586 And now it's not null.
\00:45:51.886 --> 00:45:54.826 But I suspect that something else triggered this rerender.
\00:45:56.376 --> 00:45:59.699 Well, now we're in a use effect for the bidding factory, so it
\00:45:59.699 --> 00:46:03.126 picked it up that time. And then again obviously breaks the page
\00:46:03.126 --> 00:46:05.446 because Seth Config is null, which is fine.
\00:46:09.446 --> 00:46:13.756 Can't perform? Yeah state update on unmounted component. OK.
\00:46:27.186 --> 00:46:28.756 Yeah, that's what I figured.
\00:46:30.226 --> 00:46:32.896 Bing, which it calls that, OK.
\00:46:49.376 --> 00:46:52.406 They both of these returns if config or null.
\00:46:55.776 --> 00:46:57.036 Recall correctly.
\00:46:59.806 --> 00:47:02.846 Go look at the CEF config slice.
\00:47:04.006 --> 00:47:07.016 So if config or null it will return null until it's.
\00:47:11.526 --> 00:47:12.396 Yeah, well, you know.
\00:47:15.276 --> 00:47:16.386 And more.
\00:47:17.656 --> 00:47:18.626 Evolves to null.
\00:47:19.716 --> 00:47:21.186 And I'll get set once it's resolved.
\00:47:28.946 --> 00:47:29.276 Hmm.
\00:47:33.436 --> 00:47:33.676 Well.
\00:47:37.956 --> 00:47:38.756 Is it some?
\00:47:39.496 --> 00:47:41.396 Falseness that's screwing with me.
\00:47:42.936 --> 00:47:43.346 No.
\00:48:18.216 --> 00:48:21.741 My blind or these errors new or have they been here the entire
\00:48:21.741 --> 00:48:24.146 time and I've just been looking over them?
\00:48:42.446 --> 00:48:45.256 Said also has a use bidding factory on it.
\00:48:59.196 --> 00:49:01.136 I think I can comment that one out.
\00:49:03.016 --> 00:49:05.436 This technically does that internally if I remember.
\00:49:31.446 --> 00:49:35.866 Cannot flush updates when react is already rendering.
\00:49:38.036 --> 00:49:39.466 Ohh yeah well.
\00:49:40.366 --> 00:49:41.076 Shut up.
\00:49:43.136 --> 00:49:45.744 I think that might be what's actually breaking this.
\00:49:45.744 --> 00:49:47.466 Something in here is being stupid.
\00:50:14.396 --> 00:50:16.466 I guess maybe the callback is not.
\00:50:18.806 --> 00:50:19.746 Safe.
\00:50:21.866 --> 00:50:22.716 Question mark.
\00:51:37.666 --> 00:51:38.576 Just for laughs.
\00:51:54.076 --> 00:51:58.276 Still happens. You stayed no for the current lot.
\00:51:59.766 --> 00:52:02.076 Ohly guess something else is setting it.
\00:52:05.156 --> 00:52:05.556 No.
\00:52:06.586 --> 00:52:08.376 To commented out, nothing sets it.
\00:52:09.886 --> 00:52:10.876 Like it's red.
\00:52:23.696 --> 00:52:27.546 How about bring this back? Comment out the entire that.
\00:52:37.346 --> 00:52:39.226 OK, I've had enough of this break point.
\00:52:40.546 --> 00:52:41.476 And this one.
\00:52:42.206 --> 00:52:42.986 Same problem.
\00:52:58.056 --> 00:52:59.856 That only happen once this time, though.
\00:53:04.506 --> 00:53:07.076 Specific Planet highlights is the set Lot 1.
\00:54:18.786 --> 00:54:20.876 Maybe it has to do with the sharing, uh.
\00:54:22.836 --> 00:54:23.646 Connection.
\00:54:24.576 --> 00:54:26.856 If you just slightly rearrange.
\00:54:34.936 --> 00:54:37.016 Resolver is only to run the setup.
\00:54:37.816 --> 00:54:41.189 We take the result of the setup which returns the hub
\00:54:41.189 --> 00:54:41.876 connection.
\00:54:43.766 --> 00:54:45.416 And set our local 1 to that.
\00:54:52.256 --> 00:54:55.046 Yeah, I think that might have actually maybe been the problem.
\00:54:57.766 --> 00:55:02.473 Yeah, that was it. OK, alright. So it was a. It was me using my
\00:55:02.473 --> 00:55:03.576 own code wrong.
\00:55:05.096 --> 00:55:08.805 For anybody that hasn't seen this yet, I wrote this utility
\00:55:08.805 --> 00:55:10.226 class called Promissor.
\00:55:10.986 --> 00:55:13.306 And what it does is.
\00:55:16.536 --> 00:55:20.826 It effectively acts as a promise and promise result cacher. Umm,
\00:55:20.826 --> 00:55:24.984 so that if you have static data that you will need to run once
\00:55:24.984 --> 00:55:29.274 or just any kind of promise that only needs to run once you call
\00:55:29.274 --> 00:55:33.299 promise dot resolve you give it a unique key to identify the
\00:55:33.299 --> 00:55:37.589 promise and then a function that returns the promise if it's not
\00:55:37.589 --> 00:55:41.681 already in the cache. You can also optionally ask it to cache
\00:55:41.681 --> 00:55:45.376 the result or not but it will always cache the promise.
\00:55:46.506 --> 00:55:47.006 Umm.
\00:55:48.146 --> 00:55:52.046 But what this effectively does then is looking back at this.
\00:55:52.746 --> 00:55:56.731 Uh, or actually where the signal R1 is? Yeah, this piece right
\00:55:56.731 --> 00:55:59.957 here promiser dot resolve initialize signalr. This
\00:55:59.957 --> 00:56:03.941 effectively makes sure that only one thing ever actually calls
\00:56:03.941 --> 00:56:07.926 this setup Signalr connection class and then it will cache the
\00:56:07.926 --> 00:56:09.886 result of that in the promises.
\00:56:10.456 --> 00:56:14.369 Uh, in the promise itself? So then after this point, let's say
\00:56:14.369 --> 00:56:18.157 that this call takes 5 seconds. It's a lot. Oops, it's a lot
\00:56:18.157 --> 00:56:22.256 faster than that. Let's say that setup Signalr connection takes 5
\00:56:22.256 --> 00:56:24.056 seconds if 27,000 components.
\00:56:24.656 --> 00:56:28.597 You know, mount on the page and all call promiser dot resolve
\00:56:28.597 --> 00:56:32.727 this. This makes sure that this actual function only gets called
\00:56:32.727 --> 00:56:36.604 once and the promise that's still in flight gets returned to
\00:56:36.604 --> 00:56:37.366 all of them.
\00:56:38.116 --> 00:56:40.966 So then they can all dot, then and do whatever they need to do.
\00:56:41.606 --> 00:56:44.216 The problem that happened was.
\00:56:45.106 --> 00:56:46.776 The.
\00:56:47.506 --> 00:56:51.485 The Promisor is being called by multiple components because our
\00:56:51.485 --> 00:56:55.526 multiple things trying to bid on that page and they were the the
\00:56:55.526 --> 00:56:59.256 setter logic for state inside this specific code was inside
\00:56:59.256 --> 00:57:03.296 the resolver inside the resolve. So several things were awaiting
\00:57:03.296 --> 00:57:07.151 that and then they all ran the set connection for other hooks
\00:57:07.151 --> 00:57:09.326 inside of the promisor instead of.
\00:57:10.206 --> 00:57:14.087 In and of themselves. So now this just returns the
\00:57:14.087 --> 00:57:15.836 initialized connection.
\00:57:16.566 --> 00:57:20.621 And then once the promise is done once Promiser has resolved
\00:57:20.621 --> 00:57:24.875 the the final hub connection for everyone, then each individual
\00:57:24.875 --> 00:57:26.736 person waiting on that will.
\00:57:28.496 --> 00:57:29.156 Do their thing.
\00:57:29.856 --> 00:57:31.326 So that.
\00:57:32.146 --> 00:57:32.906 Was weird.
\00:57:35.166 --> 00:57:37.956 Some weird, annoying red herrings too, from the. Uh.
\00:57:39.586 --> 00:57:40.036 Uh.
\00:57:40.676 --> 00:57:44.126 From the air output complaining about the lot timer widget when
\00:57:44.126 --> 00:57:45.796 it was in fact not the problem.
\00:57:49.356 --> 00:57:53.606 But now I do this and then I think in here I did some.
\00:57:55.346 --> 00:57:58.026 Stuff I didn't need anymore this.
\00:57:59.836 --> 00:58:00.246 That.
\00:58:03.506 --> 00:58:06.256 Now we should be able to do this.
\00:58:07.186 --> 00:58:08.426 Yep. All right. There we go.
\00:58:09.426 --> 00:58:11.156 Ignore this, I broke it.
\00:58:13.946 --> 00:58:14.546 That was me.
\00:58:17.226 --> 00:58:23.116 But Ohly, let's see today local.
\00:58:25.306 --> 00:58:30.256 And I ought to be able to sign in over here as Joe Schmoe.
\00:58:31.636 --> 00:58:32.566 They already won.
\00:58:34.156 --> 00:58:34.316 Yeah.
\00:58:35.266 --> 00:58:38.923 Queue which that all uses the new Redux school state stuff,
\00:58:38.923 --> 00:58:39.776 which is nice.
\00:58:40.876 --> 00:58:43.795 And I can bid on this since I'm not winning. You can see that
\00:58:43.795 --> 00:58:44.736 clarity admin which.
\00:58:45.376 --> 00:58:48.551 Don't ask why it's All Stars. Clarity admin is winning, hence
\00:58:48.551 --> 00:58:51.366 the Crown and the fact that I can't place another bid.
\00:58:52.356 --> 00:58:53.426 Place bid over here.
\00:58:54.896 --> 00:58:56.736 It goes through updated it.
\00:58:57.476 --> 00:59:00.264 This is the first time, by the way, that I'm testing all the
\00:59:00.264 --> 00:59:03.096 bidding functionality. After changing all the Redux stuff so.
\00:59:03.886 --> 00:59:04.416 Uh.
\00:59:05.646 --> 00:59:09.166 If I seem surprised that it's working, it's because I kind of
\00:59:09.166 --> 00:59:09.336 AM.
\00:59:10.226 --> 00:59:10.676 I.
\00:59:13.486 --> 00:59:17.286 Yay, it's all fast and stuff.
\00:59:18.756 --> 00:59:19.906 I'm satisfied.
\00:59:24.546 --> 00:59:28.077 Alright, well, there's going to be other stuff that doesn't work
\00:59:28.077 --> 00:59:31.608 yet, but let's go. Let's go on a journey. So I haven't looked in
\00:59:31.608 --> 00:59:32.096 here yet.
\00:59:34.796 --> 00:59:38.654 OK, hold on. This seemed to work. Account profile. I should
\00:59:38.654 --> 00:59:42.641 probably. I'm gonna go and close this. Let me do this. Always
\00:59:42.641 --> 00:59:43.926 have dev tools open.
\00:59:45.046 --> 00:59:47.482 Hard reload the page. It's only four from getting is customers
\00:59:47.482 --> 00:59:49.066 in the dev server, so it doesn't matter.
\00:59:50.886 --> 00:59:53.426 OK, this would I really thought wasn't going to work.
\00:59:54.316 --> 00:59:56.366 I'm pretty surprised this worked like a lie.
\00:59:57.816 --> 00:59:58.346 Umm.
\00:59:59.196 --> 01:00:02.031 Who really cool thing though? Something that anybody who's
\01:00:02.031 --> 01:00:04.336 been working in react for a bit probably knows.
\01:00:06.706 --> 01:00:07.926 Note that.
\01:00:08.906 --> 01:00:12.199 And we'll filter down to XHR. The only calls made for this
\01:00:12.199 --> 01:00:15.436 page. There were two current user calls. I don't know why
\01:00:15.436 --> 01:00:18.841 that is, but we load the cache counter which is normal. This
\01:00:18.841 --> 01:00:22.245 call I actually need to delete because we're no longer using
\01:00:22.245 --> 01:00:25.036 it. This one is just a translations, so these two
\01:00:25.036 --> 01:00:28.719 pretend they're not here, but we have a current cart call for the
\01:00:28.719 --> 01:00:32.347 quote cart and the normal cart, and that's to show them up here.
\01:00:32.347 --> 01:00:35.807 Even though the quote cart one shouldn't be happening because
\01:00:35.807 --> 01:00:36.086 I've.
\01:00:36.806 --> 01:00:39.596 Boats turned off, so we'll look at that. The tracking snippet,
\01:00:39.596 --> 01:00:42.298 which also should be happening, cause I have tracking turned
\01:00:42.298 --> 01:00:45.132 off, so there's just a handful of things that aren't respecting
\01:00:45.132 --> 01:00:47.834 self configs that was already that way. And then we have the
\01:00:47.834 --> 01:00:50.136 pre auth check to see if I'm logged in, which I am.
\01:00:50.896 --> 01:00:51.566 Umm.
\01:00:52.436 --> 01:00:55.426 And so, because the PREAUTH check passes, current user runs.
\01:00:56.196 --> 01:00:59.380 So now there's current user that's and then something is
\01:00:59.380 --> 01:01:02.730 making this duplicate. I bet it's just a hard coded call in
\01:01:02.730 --> 01:01:04.126 some component somewhere.
\01:01:11.916 --> 01:01:12.146 No.
\01:01:12.846 --> 01:01:13.626 Uh, slice.
\01:01:14.466 --> 01:01:17.499 Alright, so then what's this one coming from? Yeah, there it is.
\01:01:17.499 --> 01:01:20.438 This. This one appears the one that's hard coded in my profile
\01:01:20.438 --> 01:01:23.423 dot TSX. So we'll fix that. It should be using the current user
\01:01:23.423 --> 01:01:23.936 from Redux.
\01:01:25.506 --> 01:01:28.666 Be that right now, my profile DSX.
\01:01:51.426 --> 01:01:55.416 And once I'm done with this, these are also not going to be.
\01:01:57.726 --> 01:01:58.326 Umm.
\01:02:02.356 --> 01:02:05.038 Now let's set user in a set current user. Yeah, these are
\01:02:05.038 --> 01:02:08.042 also not going to be doing like part of the problem that we have
\01:02:08.042 --> 01:02:10.076 right now is that components like this one.
\01:02:10.826 --> 01:02:14.589 That update the current user, their manually calling CV API
\01:02:14.589 --> 01:02:18.288 dot contacts dot get current user and doing all this stuff
\01:02:18.288 --> 01:02:21.925 that you know it doesn't. Components shouldn't be worried
\01:02:21.925 --> 01:02:26.000 about the finer logic like this. The actual individual component
\01:02:26.000 --> 01:02:29.637 should simply render what they're given in state, whether
\01:02:29.637 --> 01:02:32.646 it's props, its own state or global state. But.
\01:02:33.506 --> 01:02:36.860 Nearly everything all over the place kind of just does the
\01:02:36.860 --> 01:02:37.996 logic all by itself.
\01:02:38.086 --> 01:02:41.136 Umm and that ends up making us have a ton of places where we
\01:02:41.136 --> 01:02:44.036 have duplicate implementations of the same thing. There's
\01:02:44.036 --> 01:02:46.736 there's like four or five different places that we're
\01:02:46.736 --> 01:02:49.786 handling login before this, and there's a bunch of different
\01:02:49.786 --> 01:02:52.736 places that are doing add to cart. And so this unifies all
\01:02:52.736 --> 01:02:55.886 that into one place where if we need to add features or change
\01:02:55.886 --> 01:02:57.836 stuff, we just change it in one place.
\01:02:58.806 --> 01:03:02.428 And makes it much, much easier to debug when something's not
\01:03:02.428 --> 01:03:04.446 working and et cetera, et cetera.
\01:03:05.806 --> 01:03:06.766 You'll know what it is.
\01:03:07.536 --> 01:03:10.126 Umm but anyhow.
\01:03:11.196 --> 01:03:12.766 Don't need this anymore? Let's see.
\01:03:13.996 --> 01:03:16.126 See how much that made this page explode?
\01:03:18.866 --> 01:03:21.096 OK. Well, it's still making two calls.
\01:03:29.786 --> 01:03:30.506 Yeah, right.
\01:03:31.396 --> 01:03:34.560 Get current user profile information ohk OK, so just has
\01:03:34.560 --> 01:03:37.946 a use effect to make that call. The moment this thing loads.
\01:03:39.196 --> 01:03:39.846 That's why.
\01:03:42.076 --> 01:03:44.416 Alright, what if I just?
\01:03:45.936 --> 01:03:47.286 Kill all of that.
\01:03:54.766 --> 01:03:57.546 Say it's got some warnings that I don't care about, but.
\01:03:59.186 --> 01:04:02.020 Probably going to break this page. Yeah, I kind of figured
\01:04:02.020 --> 01:04:04.036 that was gonna make it burst into flames.
\01:04:09.726 --> 01:04:11.996 I don't want it to do that anyway, that's fine.
\01:04:13.416 --> 01:04:16.550 It has use current users so it shouldn't need to do anything
\01:04:16.550 --> 01:04:16.806 else.
\01:04:20.506 --> 01:04:22.096 So what is the problem then?
\01:04:43.086 --> 01:04:43.536 Ah.
\01:04:45.956 --> 01:04:46.946 Well, that's terrible.
\01:04:47.906 --> 01:04:50.577 This is how it was setting all the values on all those those
\01:04:50.577 --> 01:04:52.896 manually calling set value on all those text fields.
\01:04:53.616 --> 01:04:57.237 OK. So we kind of sort of need to keep some of this just so
\01:04:57.237 --> 01:04:58.866 this component still works.
\01:05:01.106 --> 01:05:04.553 But anyway, the thing that I was gonna show is this is way less
\01:05:04.553 --> 01:05:07.837 requests than it previously made. It used to request all the
\01:05:07.837 --> 01:05:10.960 data for everything all the time, no matter what page you
\01:05:10.960 --> 01:05:14.191 were on. It was like 12. I think when I last counted 17 XHR
\01:05:14.191 --> 01:05:17.583 requests on page load for any for any page home page where the
\01:05:17.583 --> 01:05:20.922 only thing that's showing is your user name. It was making 17
\01:05:20.922 --> 01:05:21.406 requests.
\01:05:22.066 --> 01:05:24.937 And now you see that nothing has actually needed the current
\01:05:24.937 --> 01:05:27.667 account until I click over here. Something needed current
\01:05:27.667 --> 01:05:30.632 account, so it loaded current account the first time something
\01:05:30.632 --> 01:05:31.526 actually needed it.
\01:05:32.206 --> 01:05:35.357 Uh, same with address book. Nothing's needed it, so it's not
\01:05:35.357 --> 01:05:38.248 loaded. Click in here and it loads address book for the
\01:05:38.248 --> 01:05:41.244 current account and populates the page. Same with wallet,
\01:05:41.244 --> 01:05:44.652 except that apparently I haven't wired this page up yet, so let's
\01:05:44.652 --> 01:05:47.802 just pretend that that didn't not work. But anyway. And then
\01:05:47.802 --> 01:05:50.590 when I click back on these pages, the data is already
\01:05:50.590 --> 01:05:53.637 there. It's creating tracking records for all of these, so
\01:05:53.637 --> 01:05:54.876 let's just pretend that.
\01:05:56.366 --> 01:05:58.324 All is in here because that's not even supposed to be
\01:05:58.324 --> 01:05:58.686 happening.
\01:06:00.506 --> 01:06:03.909 Yeah, you can see just the number of requests for browsing
\01:06:03.909 --> 01:06:07.542 the user dashboard is orders of magnitude smaller, so that's a
\01:06:07.542 --> 01:06:10.425 massive win for just page performance in general,
\01:06:10.425 --> 01:06:14.116 especially on mobile. And it's also less work the server has to
\01:06:14.116 --> 01:06:17.403 do, even if it's serving a response from a cache, that's
\01:06:17.403 --> 01:06:20.978 still some work the server has to do. So the more we can keep
\01:06:20.978 --> 01:06:22.016 that to a minimum.
\01:06:22.976 --> 01:06:24.796 The more scalable we are so.
\01:06:25.496 --> 01:06:26.286 UM.
\01:06:27.366 --> 01:06:28.366 Yeah, pretty neat.
\01:06:29.206 --> 01:06:29.936 Umm.
\01:06:33.026 --> 01:06:33.886 Figure out why this.
\01:06:35.506 --> 01:06:36.256 It's weird.
\01:06:37.656 --> 01:06:41.571 So this use effect needs to run every time current user changes.
\01:06:41.571 --> 01:06:45.245 That way once it's set from global state, I can steal all of
\01:06:45.245 --> 01:06:45.606 these.
\01:06:50.016 --> 01:06:51.426 Weird things down here.
\01:06:55.436 --> 01:06:56.196 These.
\01:07:00.056 --> 01:07:02.186 Your result data, it's going to be current user.
\01:07:03.096 --> 01:07:05.619 And this isn't gonna be. That's gonna be current user dot
\01:07:05.619 --> 01:07:05.966 contact.
\01:07:08.516 --> 01:07:10.426 If not current user.
\01:07:11.796 --> 01:07:15.506 Actually it's if current user dot loading.
\01:07:23.426 --> 01:07:26.828 Actually, I think the most robust way to do this is if the
\01:07:26.828 --> 01:07:30.461 current user ID is greater than zero, i.e. The current user is
\01:07:30.461 --> 01:07:30.806 valid.
\01:07:31.696 --> 01:07:33.406 Steal all that stuff.
\01:07:34.616 --> 01:07:37.906 And then we steal all of this.
\01:07:38.826 --> 01:07:41.666 Dump it in here and then comments.
\01:07:45.716 --> 01:07:49.745 And now this page will probably work again correctly with global
\01:07:49.745 --> 01:07:50.116 state.
\01:07:52.766 --> 01:07:56.016 Because this is already doing a dispatch set user. Just cool.
\01:08:00.666 --> 01:08:01.456 Yeah. Let's see.
\01:08:03.186 --> 01:08:06.768 Yay it all updated. Now let's see if this works. I wanna
\01:08:06.768 --> 01:08:08.716 change my display name back to.
\01:08:09.506 --> 01:08:11.376 Clarity admin said of the stars.
\01:08:14.506 --> 01:08:16.026 Is this password?
\01:08:17.866 --> 01:08:19.246 Ah yes.
\01:08:20.356 --> 01:08:21.446 A text field.
\01:08:22.786 --> 01:08:26.185 Password field that has validation for password that
\01:08:26.185 --> 01:08:27.146 already exists.
\01:08:29.246 --> 01:08:30.076 Let's go fix that.
\01:08:30.796 --> 01:08:31.506 Got him.
\01:08:35.056 --> 01:08:37.126 I think it's suppressed requirements.
\01:08:38.226 --> 01:08:42.026 I built this in because there are a couple of places where.
\01:08:43.456 --> 01:08:46.361 Actually this one does need requirements, cause that's if
\01:08:46.361 --> 01:08:49.567 you're changing, you're changing your passwords. That does need
\01:08:49.567 --> 01:08:52.221 to impose new password requirements, but the current
\01:08:52.221 --> 01:08:55.126 password field should not require me to meet the existing
\01:08:55.126 --> 01:08:55.576 password.
\01:08:56.366 --> 01:08:58.486 Requirements in case those requirements change.
\01:08:59.706 --> 01:09:02.570 It doesn't make any sense to require that like the I I
\01:09:02.570 --> 01:09:05.954 literally just couldn't until I fixed that, I literally couldn't
\01:09:05.954 --> 01:09:08.921 log in to the storefront as my clarity admin on my local
\01:09:08.921 --> 01:09:11.576 because my password doesn't have a capital letter.
\01:09:12.516 --> 01:09:16.136 So hey so-called update called current user which updated and
\01:09:16.136 --> 01:09:18.996 Redux which updated my name up here immediately.
\01:09:19.656 --> 01:09:23.296 Yay, we did it. So that page is fixed now.
\01:09:23.936 --> 01:09:26.320 To look at Wallet, I guess we're running out of time by the way,
\01:09:26.320 --> 01:09:26.906 and that's fine.
\01:09:28.266 --> 01:09:29.976 Guessing it's this one. Yeah. Alright.
\01:09:31.356 --> 01:09:34.266 Use wallet is right here wallet.
\01:09:36.796 --> 01:09:38.946 Selector preload wallet.
\01:09:45.576 --> 01:09:46.186 Hmm.
\01:09:47.416 --> 01:09:48.796 The seemed like it should have worked.
\01:09:50.376 --> 01:09:51.286 So.
\01:10:01.376 --> 01:10:02.326 In the wallet.
\01:10:08.436 --> 01:10:09.006 Look, I'm all.
\01:10:09.716 --> 01:10:11.916 And never ran. OK so.
\01:10:12.926 --> 01:10:13.426 That sucks.
\01:10:19.776 --> 01:10:24.301 All it turns into array wallet models or null, which by default
\01:10:24.301 --> 01:10:24.866 is null.
\01:10:30.146 --> 01:10:30.676 That's why.
\01:10:31.856 --> 01:10:34.680 It was not by default, though the initial state was an empty
\01:10:34.680 --> 01:10:37.086 array, so this never ran because it was never null.
\01:10:37.906 --> 01:10:39.316 Now it's art.
\01:10:45.696 --> 01:10:48.046 Oh, fantastic.
\01:10:49.086 --> 01:10:52.459 And again, if I go back to my profile and then refresh this
\01:10:52.459 --> 01:10:56.000 page, it does not request the wallet info until I click on the
\01:10:56.000 --> 01:10:59.147 wallet page and then it requested it with these two two
\01:10:59.147 --> 01:11:00.046 calls two calls.
\01:11:01.476 --> 01:11:01.806 Why?
\01:11:04.316 --> 01:11:07.875 Who's OK? There's a hard coded one and the get user wallet
\01:11:07.875 --> 01:11:08.236 again.
\01:11:08.946 --> 01:11:11.554 That's the kind of stuff I'm fixing. Components should not
\01:11:11.554 --> 01:11:13.896 have to know how to load a wallet, they should just.
\01:11:14.916 --> 01:11:18.615 Ask something that knows how, so this is where it is. Get user
\01:11:18.615 --> 01:11:19.026 wallet.
\01:11:19.826 --> 01:11:24.116 Where's this called in way too many places. Alright, fantastic.
\01:11:24.836 --> 01:11:27.975 Uh, well, we're not going to load it on startup, that's for
\01:11:27.975 --> 01:11:28.236 sure.
\01:11:29.116 --> 01:11:32.432 Gazer wallet. There's also going to be a wallet factory that I
\01:11:32.432 --> 01:11:35.642 haven't built yet that will handle this, add new user or add
\01:11:35.642 --> 01:11:38.853 user wallet, item deactivate, et cetera. That's all gonna go
\01:11:38.853 --> 01:11:42.115 through a factory. So that once again, this component doesn't
\01:11:42.115 --> 01:11:42.536 have to.
\01:11:43.206 --> 01:11:45.936 Implement all these direct calls to CV API.
\01:11:46.826 --> 01:11:49.427 And if anything else wants to work with the wall, it doesn't
\01:11:49.427 --> 01:11:50.236 have to copy paste.
\01:11:51.136 --> 01:11:54.089 All of this code into a different component. It can just
\01:11:54.089 --> 01:11:54.866 call a factory.
\01:11:55.566 --> 01:11:57.586 Or a service or whatever you want to call them.
\01:12:06.196 --> 01:12:06.746 So yeah.
\01:12:08.766 --> 01:12:09.936 What if I just?
\01:12:11.136 --> 01:12:11.766 Said.
\01:12:12.476 --> 01:12:13.096 No, Sir.
\01:12:14.606 --> 01:12:16.536 Few things lose their mind.
\01:12:17.426 --> 01:12:18.316 As expected.
\01:12:20.266 --> 01:12:21.386 This comment this out.
\01:12:22.866 --> 01:12:25.624 I'm. I'm gonna have to continue working on this. You know,
\01:12:25.624 --> 01:12:27.306 obviously it's not quite there yet.
\01:12:28.976 --> 01:12:32.106 But that's the idea. It's it's.
\01:12:32.896 --> 01:12:35.734 Making the logic in a lot of these components much simpler,
\01:12:35.734 --> 01:12:37.436 they no longer have to worry about.
\01:12:38.546 --> 01:12:41.170 Where data is coming from, what kind of validation is needed,
\01:12:41.170 --> 01:12:43.836 they just consume a service that provides them the information
\01:12:43.836 --> 01:12:45.486 they need and they render their state.
\01:12:46.506 --> 01:12:48.456 So components become.
\01:12:49.296 --> 01:12:52.574 Components. They become renderable blocks of stuff they
\01:12:52.574 --> 01:12:56.261 are no longer the the business logic agents that they are now.
\01:12:56.261 --> 01:12:56.436 So.
\01:12:58.056 --> 01:13:01.336 But yeah, I hope this was useful. I hope this was a.
\01:13:02.536 --> 01:13:03.546 Uh, enlightening.
\01:13:04.686 --> 01:13:07.276 It's certainly been an enlightening journey for me.
\01:13:09.906 --> 01:13:13.525 Yeah. Any any questions and we're a little after four, so
\01:13:13.525 --> 01:13:14.336 feel free to.
\01:13:15.856 --> 01:13:16.316 Uh.
\01:13:17.486 --> 01:13:20.492 Feel free to drop if you need to. I'm gonna be jumping off
\01:13:20.492 --> 01:13:21.816 here in just a moment, so.
\01:13:25.726 --> 01:13:26.716 No man, thanks.
\01:13:27.676 --> 01:13:28.796 Yeah, I will learn quite a bit.
\01:13:29.646 --> 01:13:34.123 Sweet, that is I I I definitely know that I rambled for 95% of
\01:13:31.016 --> 01:13:31.646 Thank you.
\01:13:34.123 --> 01:13:37.746 that, so I'm glad someone got something out of it.
\01:13:38.946 --> 01:13:43.881 Well, cool. Have a good weekend and I will talk to you all next
\01:13:43.881 --> 01:13:44.266 week.
\01:13:46.426 --> 01:13:47.046 Thanks Sir.
\01:13:47.826 --> 01:13:49.096 Yeah, I have a good weekend guys.
\01:13:49.846 --> 01:13:50.346 See you all later.
\01:13:51.626 --> 01:13:52.026 The.