Jon (00:01.306) Hey everybody, welcome back to Gone Mobile this week. Alan, were gonna do a little bit different of a format. You listed a buffet of topics, a Buffet, if you will, just like the Jimmy Buffet Margaritaville restaurant that we had the pleasure of eating at in Chicago this past weekend. Allan (00:16.386) Yeah, there we go. Allan (00:29.465) You know what's funny is that when I put that there and just before we started this podcast, because John's usually like, yeah, I got a good one to open up with. I like, I knew I actually, I actually predicted that joke. He didn't tell me. Jon (00:44.464) I also, I never claimed it was going to be good. I said I had something. Yeah. Allan (00:49.487) Well, they rarely are, I mean, they're good singers, but anyhow, I predicted that one. I'm getting this. That was almost like me leading the witness here. The buffet of topics. Jon (01:00.194) I, and given that experience, you know, I think we might have another Disney episode in the future just because I gotta get the experience of taking younger kids to a city like Chicago out of my recent memory. Cause I don't know, if you're gonna spend that much money, I may as well just go somewhere that everyone's happy. Allan (01:26.173) All right well I got a good idea for that one. When we get to the Disney one, when you're ready to talk Disney app architecture again, I got a cool one. All right. Jon (01:28.684) Okay. All right. Jon (01:35.792) Let's do that. So, but they have topics. we, haven't, there's just been a lot of little things collecting that we haven't taken the time to, you know, really carve out space for. They don't do it. They're not going to fill a whole episode. one of the things we've been neglecting is talking about any listener feedback that we always, you know, solicit everyone for, and then, forget to actually do anything with it. we should, we should probably start with that. So, One of the listeners, thank you. think it was, no, I'm looking at several of them. We have a couple of things. But one of the listeners was writing in a while back about their app that they're building with Maui. And it sounded pretty cool. They're a tattooist and hobbyist programmer, which is, I don't know. How do you like, I've never thought about being a tattooist. don't, I'm probably not cool enough, but no, no, well, that doesn't help either. Allan (02:28.888) Can you draw though? Because if you can't draw it'd be really bad. It'd be like some sort of stick figure on somebody's butt cheek and it would be bad. Jon (02:35.026) yeah. And maybe that's why I'm kind of like fascinated by it I feel like it's not unusual for developers to not be the most like artistic, not, you know, creative is one thing, but like able to like do the art thing is another. Allan (02:53.689) There's only one guy I can think of in the community that does like artwork because we both have one of his like, cartoon, like he takes a picture of yourself and he converts it into like, I forget what his name was, but I have one. I'm pretty sure you have one. Jon (02:57.988) Mm -hmm. Jon (03:08.12) I did one just so it matched on the website and didn't have to be like the reality of my face. Allan (03:11.0) Yeah. So, I mean, there's not many though. Okay. Jon (03:19.234) No, no, I don't think so. So, so yeah, this, this person is, and makes snap. They are storing all of their data in SQLite locally, with, think an option to backup, you know, basically the encrypted database somewhere. so like manage your own backup and stuff, but otherwise like the thing on your device is the data that's there. And you know, they're, they're kind of like asking and telling about this approach and like, Hey, is this, does this seem like reasonable? And it's like, keeping most of the stuff client side. It's like we've kind of come full circle in some ways to the old, you know, old days where, yeah, yeah. So we're kind of moving back to the like, hey, let's offload more work onto the client side now, right? Like with web assembly and stuff too, that's kind of what I think. That's why one of the reasons I chose to kind of do that in pool math too was like, I don't know, I don't want to run the server for some of this stuff. Like I have a server, but. Allan (03:55.662) Thick Client. Jon (04:15.63) you can do all the processing of stuff locally. I think it's a really kind of simplistically neat and tidy, nice way to do it, you know, just to have it like there's, there's no, there's no server stuff involved because you don't kind of really need it in this situation. Everything just happens locally. Everything's on the app, on the device. It's neat and tidy. Like I, I'm a fan of the architecture for certain scenarios that require that not require, but that can work that way. I'm curious what your thoughts are on it too. Allan (04:49.727) The easiest thing to say is that if it works for your business, it works for your business and that's. That the sum of it. What he's saying is it works well for for what he's done. If people are using the app then. Nothing else really matters, does it like? That's awesome and and frankly he's saving money on the server costs anyways. Right, all that chatter that you don't have to pay Azure for, which yeah, it's inexpensive, but still. Jon (04:53.657) Mm Jon (05:06.287) Right. Jon (05:13.346) And yeah. Allan (05:19.735) I mean, it's a couple hundred bucks that you don't have to pay. Yeah. Jon (05:21.614) And it's more stuff to set up, right? It's just, it's more things that can go wrong. So like, yeah, if it's working for you, I think it's a great way to go. and yeah, you're, you know, he's right about the, processing power on devices these days. Like there's so much on tap potential. Like every year the iPhone is the fastest iPhone ever that's been released. And it's like, these things can do so much more than most people do. Yeah. I know. Allan (05:35.511) Yeah. Allan (05:44.27) They can play AAA games, John. I got that iPhone Pro, finally. You were trying to convince me, but I didn't bend. But they didn't bring me my foldable phone. So I got the iPhone 15 Pro and it plays good games. Like good. Jon (05:54.842) Yeah. Jon (05:59.3) Yeah. And that's like such a fraction of what most people use these things for. like throwing up a local database and doing some more like reporting and processing totally, you know, I think the way to go and I'm, you know, pool math is not just client side, but like I've, I've leaned more into this and actually I it's kind of a timely thing to talk about. I've been working on, Allan (06:05.515) Yeah. Jon (06:24.792) changing up a little bit about how I store stuff in the app and doing more stuff locally. So when I first started the app, I, I would, you if you had like test logs and stuff, I have the concept of this like overview and the overview is like the latest, you know, different records from here and here and here, like pieces of data from them, like a couple, like a value and a timestamp, basically the actual record contains more information, but I don't care about it in this context. And so Allan (06:35.916) Okay. Allan (06:46.551) Okay. Jon (06:51.992) I used to, whenever you saved that record, I would go update the overview record, right? And then that would get pulled down. it's not normalized database stuff, right? But it's kind of the whole document DB idea of like, you can write more stuff to more places if it means faster reads or more aligned to how you're using the data kind of thing. So I've been changing. Allan (06:58.018) Okay. Allan (07:17.346) Yep. Yep. And again, still works for your business. That's right. Jon (07:22.4) yeah, yeah, yeah. And it works, but at the same time, you know, I've started being like, can simplify a lot of my logic and stuff. If I have a database on the client side now too, I can just query this data. Like these phones can do that. It's not a big deal to do that. And so I have this massive query for SQLite. That's like a whole bunch of like some queries and it runs in like 10 milliseconds. Like it's fine. Allan (07:44.151) Yeah, mean, SQLite though is a pretty, I don't think people realize that, well, it's not really multi -threaded, which is fine. from its queries, first of all, the query that you're writing was probably pretty jiggy if it's got a lot of subqueries anyways. And it just chews it up like nothing. So it's amazing how far it's come. It's like SQLite and Postgres, they're query parsing engines and all that stuff. Jon (07:52.228) Right. Jon (08:00.328) it's horrible. Allan (08:12.685) It's awesome and the sequel light runs literally everywhere. I mean, I can't think of anywhere where it doesn't run these days, so. Jon (08:17.05) Yeah. Jon (08:21.404) I think you'd be really hard pressed to come up with a situation in your app that you're like, no, SQLite's not gonna cut it. You really need to offload this to the server. Certainly there's cases, but yeah, like you said, if it was working for you, embrace it, it's good. Allan (08:35.725) Yeah. I have heard of people using SQLite on the server though. That sounds a little scary but I have heard of it. But hey, good job to this guy, the tattooist and the app maker. Yeah, great job. Jon (08:41.527) Yeah, I think I've done that. Yeah, thanks for writing in too. If I ever want a tattoo, maybe we can figure out where you're at and I can get a tattoo. I've never been able to get one. I don't know what I would get a tattoo of. I'm too indecisive. Allan (09:03.306) Yeah, I don't even have a comment for that one, John. I was trying to think of something clever. just don't. Jon (09:06.608) Okay, yeah, we probably shouldn't dwell on it then. Don't need any more time to think on that one. We had some other listener feedback too on the X, whatever we call it now. Yeah, people are still using it. mean, you gotta be where you gotta be. Allan (09:20.631) On the X, the excrement, excrement, the Twitter, I don't know. Yeah. I still like it. I mean, it's I still see a lot of tech news. It's harder to see tech news these days. But. Jon (09:36.954) So yeah, feedback on Mediator. Seems like Rodney's on board. I didn't follow the full thread before the show yet. I think there was some more replies. You can film me in. Allan (09:40.504) Yeah? Allan (09:48.769) I think he was just pretty happy with the overall approach. Rodney Littles, the second, he goes back. He's big into architecture. He's one of the reactive UI guys. think he still is. I'm not sure if he. Step down when he was also part of the net foundation and. All that great stuff, so Ronnie's been around for many, many years. He's pretty vocal guy, but yeah, he said he was really happy with the. with what I'm doing with mediators. So thanks for that Rodney. He's got more feedback coming he said. Jon (10:22.042) Yeah, good. Well, and hey, like, you know, as, as you continue to evolve the, library and pattern, like, you know, the more people that kind of notice it and are like, yeah, this actually makes a lot of sense to me and I want to use it. yeah, who knows? You might have a hit on your hands here. We'll see. I mean, I haven't, I haven't done it yet. I've been too busy, you know, hanging out, drinking margaritas in Chicago before the, before the city got crazy. Allan (10:36.578) Maybe. Have you converted yet, Allan (10:45.588) That's true. Did you get a deep dish pizza there? Jon (10:49.488) My one kid doesn't eat pizza. Like what kid doesn't eat pizza, right? this is part of the problem. It's like, can't even go anywhere. So it's like, okay, you're at like the Navy pier, which is everything's like a million dollars just to be there. Like you just to set your foot in the door anywhere there is like, there are a couple hundred bucks. And then you're like, okay, we got to eat. Where, where can we eat? well this place has burgers. So I guess, I guess we're safe. Great. Allan (10:53.702) I don't know man. You should just Allan (11:15.375) So you did not get a deep dish pizza while you were in Chicago. Yeah, but it's something you do again and again. Jon (11:18.712) I've done that before. I know. I know, I know. We had hot dogs, so there's that. Allan (11:26.871) All right. All right. So what else we got here in our buffet of topics? Do we have other feedback? Because you're usually the one that collects all the feedback. You get all the notifications. Jon (11:31.664) Buffet of topics. Yeah, what do you want to pick next? I think that we've got the feedback covered. I could be missing some off to check again later. But as far as the stuff I am aware of today, so keep sending it in folks. We will talk about it sometime. Promise. See? Yeah. Allan (11:42.925) Okay. Allan (11:48.386) All right. Allan (11:52.919) Yeah, he's got to got to hound John sometimes. He's the keeper of all the information. Anyhow, I noticed that there's some stuff going on with Android, the Android developer community. I'm kind of interested to see why why you're excited about Android because you know it is a. Jon (12:01.018) So what's next? Jon (12:08.696) Yeah. No, I'm not. I'm not excited. It's more of a, a loathing of the change. So Android's doing this weird thing, where they're, they're changing the page size on their platform essentially. So the, the historic page size, I believe currently is four kilobytes on, on Android and their CPUs and everything's built and aligned to that, you know, that page size. Allan (12:18.786) Yeah. Jon (12:41.136) Well, they're changing that. They're changing that to 16 kilobytes. Allan (12:46.766) Why does this concern you? Fatter pipe, more data. Jon (12:48.568) Well, because once this starts happening, the world has to be rebuilt for this, which is going to be the pain. So anything that's, if you're shipping a package with a native library component to it, not just a jar or AAR file, well, maybe an AAR file. If you have like actual like SO files, right? Like actual native libraries. Allan (13:18.172) yeah. Jon (13:19.012) That's all going to need to be rebuilt. Allan (13:23.224) does make sense. Jon (13:25.028) Yep. So that is coming and just, you know, I wanted to raise awareness to the three people that listen to this. Maybe one of them build something that has one of these in here. And largely like, I think a lot of what we see in like the Maui ecosystem is more bindings and stuff around these things. Certainly, Allan (13:27.234) because it is a different. Jon (13:49.956) like .NET, know, the Android team has their own set of native libraries for mono and know, runtime and everything. But they'll have to deal with this as well too, right? Like they're going to have to rebuild all those things and that probably means at some point we're going to have to ship both of them side by side because you know, presumably you're going to be in a world where you want to support both of them because not every device will be able to do this right off the bat. And I haven't really dug super far into all of the different, you know, aspects of this and like where support starts and stops and like what device like do current devices can they support it? Is it just OS? I truthfully have not dug into the details. Allan (14:30.735) You know what, I bet you it won't be a big deal because there'll probably be like a emulation mode of some sort, right? You know, like running 32 -bit processors in 64 for the longest time. I don't think this is going to be quite as big of a kick in the groin as you're concerned. Jon (14:38.264) I don't think so. -maybe. Jon (14:48.048) I know the Android team is not excited about this because I think it does break the world on some level for them. And I think, like I said, know, library authors and stuff will eventually have to rebuild and everything. So it's, I think it could be, it's going to be impactful. Just, just a heads up, you know, keep, keep an eye on it. I'm sure we'll say more about it in the future too. Like this is starting in Android 15, but I don't think it's a, like, I don't think it's like everything suddenly goes this path in Android 15, it's like you can start getting the tooling and stuff to start thinking about building this stuff for your app. Allan (15:23.276) It'll certainly be a performance bump though, right? Jon (15:25.648) Yep, that's the idea why they're doing it. I think they kind of generally say 5 to 10 % performance increase. So hey, free performance. Sure, great. Allan (15:34.36) Yeah, I'll tell you. I mean, if all I got to do is recompile, Jon (15:35.76) More memory usage though, right? Because you're kind of, your lowest size is now bigger. Yeah. yeah. Yep. Allan (15:41.135) Yeah, well, it was the same with when we went from 32 to 64 bit, right? Like it's just, part of it. Fatter pipe, fatter landing strip? I don't know. Jon (15:53.54) Yeah. Okay. Yeah. Let's go with that one. It's the quote of the day. Allan (15:54.946) Yeah, you know where I'm going here. That's all right. Yeah, okay. I'm a little slow today. Listen, you opened with Buffett of topics, so I don't feel too bad. Jon (16:01.848) All right, so yeah, I know. is, yeah. I mean, if we haven't lost everyone listening yet, we will in short order. Yeah, there you go. I guess that does it, right? That's all we can end there. Allan (16:10.242) They just did. We just did. Yeah, that's great. Thanks for reading. Okay. Jon (16:18.018) All right. What, so we, we, yeah, I think generally, I don't know if we're going to do this every episode. We'll probably figure out, you know, some changes here. We know what we need is some like really catchy jingles for each, each kind of section of the show. I don't know how we're going to do those AI of course. Allan (16:32.8) Yeah, I feel like, well. yeah, that's a good one. Jon (16:38.222) Like an AI doing the jingle. don't mean, I mean, maybe we want an AI section. Who knows? Everybody has AI now. Allan (16:43.311) You did get, you should talk about the AI you used for your kids when you did the Disney trip. Yeah, that was good. Jon (16:49.654) yeah, that was fun. It was a little creepy. I'm not gonna lie. did I sent you the video? Did I? Yeah. Yeah. But you know what? That's after the fact they were both like, how did you do that? How did you get that voice for that? For this? And I'm just like, I know Mickey duh. Yeah. No. I guess. Allan (16:55.658) Yeah, I saw it. It was definitely creepy, but it was hilarious. Allan (17:06.402) Hey. Allan (17:10.818) So are you going to tell everybody what you did? Or do want me to tell them what they did? Yeah. Jon (17:15.492) Yeah. So like we, we, we wanted to do the, a reveal for the trip before we went. and, part of this has been like, you know, personal reasons had kind of a crappy year. wanted the kids to have a win, wanted us to have a win. And so we, we were like, let's do the Disney thing and we're going to like reveal it to them. Like, how do we want to do that? And I'm just like, I'm just going to make a video. I'm going to get stock footage of like Disney, you know, shots for like the visuals, right? And then I started thinking, I'm like, could I get, you know, Mickey to like say, you know, my kids names and, you know, give them like a personalized message. And there's some services that you could like hire someone to do that, but I'm pretty sure they're just doing the same thing that I did. I'm like, no, I'm sure there's a way to do this with AI and there is, there was. And so I found, looked through a couple of different voices and, you know, I found actually the easiest way to do it was to record. own voice and then use that to overlay AI on top of. There are some that let you do like type out the text but they never could quite get the intonation of the whole thing right and it was much creepier sounding when when you don't get that right. So there were some that you could Allan (18:32.076) Well, I mean, it took your voice, high pitched it quite a bit, and it just sounded like a wrong sounding Mickey. But hey, you know, it was the thought that counts. Jon (18:37.561) Yeah! Jon (18:42.744) Yeah, like kind of the the uncanny valley sounding Mickey right like it was close enough to be like almost believable But you're like there's something just not right about it Allan (18:48.408) you Allan (18:53.548) Well, there's it's not quite it's pretty much fully not right Mickey, but hey man, listen, that was pretty cool. Your kids thought it was awesome. mean, seeing your daughter, was it your daughter that lost? Yeah, she lost her mind. So once she fixed it. What? Jon (18:55.993) Yeah. It was a model. Yeah. Jon (19:06.318) Yeah, yeah, and Gavin, the other one was just kind of like, what does, what does this mean? Does this, are we, what? Yeah. yeah. Yeah, probably. Yeah. He's like, I have to go to that, that Disney world. That doesn't sound good. That Mickey sounds scary. Allan (19:14.445) He was so traumatized by the Mickey voice that he just didn't know how to process. But yeah, it was. Allan (19:23.15) You Jon (19:25.882) But it worked out well. So yeah, there was a site, you like upload the WAV file to and you know, of my own recording and it did the, it applied the whatever Mickey model I chose that was kind of cool. I don't, I wonder if I canceled that subscription. It was like a paid for thing. Yeah, I'm probably paying some service, you five bucks a month out there still. well. So yeah. Allan (19:27.416) So that's a pretty cool project anyways. Allan (19:42.714) my gosh. Allan (19:49.176) There you go, John. Good job. Jon (19:54.008) We got there from talking about making jingles for different sections of the show. So we're a little lost, but... Allan (19:58.466) Well, making cool things right now. So probably more focused on apps, but you know, I thought that one was pretty cool anyways. Jon (20:06.092) Okay, okay. So yes, this is the making, the cool things we're working on section. Allan (20:12.503) Yeah, I mean, I feel like this is more my department because you get to work on a single project and you find ways. You find different ways to... I think this year will be more interesting for you, but yeah. Jon (20:16.944) That's fair. What about, mean, there's, but there's different aspects to it, right? Like there's stuff. Yeah. So what are you working on? That's cool. Allan (20:30.567) This week I did a marketing app for one of the companies I'm working with and they had some they had some custom requirements you know they wanted it it's like a kiosk thing that goes and basically there's this motor you're gonna press on a button and it turns motor I mean it sounds pretty easy right the difference is is the marketing people are gonna want to change that website all the time and it's got to communicate through either Bluetooth or serial Now there is a web serial specification. But it's not very like with all things web even web Bluetooth is like, can we just finish the spec already guys? Like, let's get on with it. Jon (21:11.28) So what are the different device components to this setup? Is there just one? Allan (21:18.914) Well, the main premise though is that they've got to get a marketing materials. So some sort of HTML website to be viewable. Okay. And then the second is they want to click on a button and have it spin a motor, right? It's, basically a marketing material to show one of their products in store. Right. So it's, it sounds pretty cool. So Jon (21:38.64) So what did you use as the hardware thing to drive this all? Allan (21:44.941) Well, I used I use Maui and I have nice little web view. Nothing too complicated. Now, the cool thing here is that it's not you can't use your general kind of web view and interop stuff because they want the marketing marketing people change their minds and colors every other week. Right. I don't know you've ever. Right. So it pulls in the web content zip file. Jon (22:06.544) So you're loading the web content from a server somewhere. Okay. Allan (22:13.463) It has its own local copy of what it was right like to start but then it goes out to the web it downloads a new one unzips it you know if they want to run a react site or hey if they want to run flash I don't know if they still can. Can you still run flash on Android? think so. I don't know. Not on iOS. Anyhow so they can run all that cool content bundle it all up and ship it. Jon (22:16.886) Mm -hmm. Mm -hmm. Jon (22:26.448) Hmm. Hmm. Maybe on Android. No. Allan (22:37.675) Movies the whole nine yards it'll run now I've got a little local web server, which I'm not going to mention yet because well, it's gonna be our package of the week as well, but This little web server called embed IO It can basically run static code like here's my WW root here's here's an API Here's some it's got the ways to do web sockets and stuff. So it's pretty it's it's a pretty powerful little web server And so because I needed to update the content, right, you can't just use like a Maui asset because it's a string build, right? So you just stick it in the app directory, ship the big giant zip file there. And wow, there's a loud, I'm not sure if you heard that, but I could hear it through my headset. Anyhow, we needed because we needed to update it. Basically the app data directory becomes the WW root and Jon (23:23.76) You Jon (23:36.421) Right. Allan (23:37.145) do what you want to do and marketing can put whatever they want. And then I've given them two little API endpoints that they can call for the device to do things. So it's pretty cool because. Jon (23:44.204) OK. So it's like API endpoints like JavaScript kind of things they call it from and you're hooking into or OK. Allan (23:52.237) Yep, just like a traditional, well, if you want to call it Ajax, a fetch call, right? So just like if it was on the web, it was calling to remote server. It just happens that that URL is local and it calls into our C sharp code to say, do something. So that's how I've done the interop is it's not really interrupt, it just call the website, call the API, tell the motor to turn on whether it's through Bluetooth. Yep. Jon (24:05.797) And... Jon (24:17.52) the website is, local host, whatever, right? So you... Allan (24:21.112) turn it on through Bluetooth or turn it on through serial, whatever we're using and it just works. It's pretty cool. Jon (24:26.082) Okay, that was what I was gonna ask is like, how is the app communicating with the motor part of it? Allan (24:31.917) Yeah, it just depends. Because on iOS, there's no such thing as a serial cable. Really? They do have ways to interact with like, like you've got one of the SanDisk USB keys. But guess what? They need that whole MFI made for iPhone junk. Yeah, you know, they're so annoying about stuff, Apple, just let us plug in and ask the user if it's all right. Jon (24:36.195) right. Jon (24:56.465) So there's no access to anything like USB like that without the whole certification. Allan (25:02.11) No, without sending a pint of blood praying to Steve Jobs grave. Jon (25:06.19) Right. Yeah. hey, mean, gotta do what you gotta do. Or Bluetooth it. Allan (25:10.35) How about making the money? Well and that's just the thing but then Bluetooth yeah there's this little it's hard to do in a kiosk mode but anyhow Jon (25:21.24) Yeah, well in a kiosk you want it to work perfect, right? So that kind of sucks. What if you, I mean I guess at this point you don't really need Maui in the mix, it's like what if you had like a raspberry pie or something that you were communicating with instead? Allan (25:24.632) Right. Allan (25:35.143) I mean, technically I could, the whole point is that this kiosk isn't going to be attached to any network, right? So it's not going to be on wifi or cellular or anything. So, you wouldn't really be, you'd either have to connect to it through, mean, there's a number of ways to still communicate with the Raspberry Pi. I mean, as it is this, this device that I'm talking about already has some Bluetooth on it that's used by the actual app and Jon (25:42.35) Right. OK. Jon (25:52.034) I mean, back to Bluetooth or something, right? So no, no savings. Jon (26:01.806) Right, okay. Allan (26:02.178) all that nine yards right so I can kind of piggyback that stuff but where was I going with my thought here yeah you don't really need a Raspberry Pi to be in front of those it's just straight basically for the motor it's you issue it two bytes and it goes it's on a timer so that's pretty cool hopefully it doesn't chop anyone's fingers off while it's running or anything but you know Jon (26:22.286) Yeah, yeah. Well, that's fun. Well, I mean, yeah, that's why you put it all behind like plexiglass and, you make it so people can't get too close and touch it. Allan (26:32.727) Alright. I don't even know what it's gonna do. They haven't sent me the toy to actually play with, because I was like, I wonder what I could do with this. It could probably scare the crap out of my cat. But maybe my kids? What's that? Jon (26:40.206) Okay. Jon (26:44.334) Yeah. Or feed your cat. Maybe you could run the motor to like do something cool to give your cat some. Yeah. Allan (26:48.931) to feed the cat. except, yeah, well, it'd be messy, but yeah, it could. Jon (26:52.592) I don't know, can you like, I don't know, hook the motor up to whatever? Allan (26:56.862) Shoot food at the cat. Are you hungry? So yeah, that was it. That was one of the cool projects I'm doing. It's done in Maui, works for iOS and Android. I mean, it's Maui in terms of hey, here's some UI other than the web view, but still, still counts. Jon (27:13.988) Yeah. I mean, I'm still always very partial to the whole world of like interacting with something like physical from a software perspective. Right. So I, that's a lot of fun. That sounds like a, pretty interesting project to work on, let alone to do it for, you a company that you're, that is presumably paying you to do it too. Allan (27:35.965) there you go. And what's cool, like all the permission stuff that I needed is mostly built in. So it's still a win project with dot net on mobile one way or the other. So. Wicked. Jon (27:45.988) Mm -hmm. Yeah. Well, that's cool. That sounds more fun than some of the stuff that I've been looking at lately. I was trying to think of it. Have I been looking at what have I been doing that's fun? Maybe less fun, but still, you know, I'm a glutton for punishment. We've talked about this stuff too, right? Like we've worked in some really weird areas of mobile and just the ecosystem that you're like, why would you punish yourself by doing this? Right? Allan (28:14.241) You Jon (28:15.952) And so one of the areas that I've over the years learned a fair bit about has just been authentication. Like, auth, all the different ways that you can do authentication flows. And especially with an eye towards mobile. like, I don't know if you remember way back in the day when we had Xamarin auth, that was a library. Allan (28:39.372) I do remember that one, yes. I never used it personally, but I did. I had heard of it. Jon (28:42.03) And Yeah. So it was, you know, it was a library. and in early days, just like everything else, like you got, when we started doing stuff, you used what was available to you. like when the idea of doing these, like, you know, off type flows from mobile was first can kind of a thing. You're basically only way to do it was like, here, I'm going to stick a web view in my app, right? I'm going to load the page, the login page that I'm, I'm targeting. from whatever server and then I'm going to just listen for the web view, the navigation event. I'm just gonna watch that and when it has a URL that contains like the right pattern that I'm looking for, I know that it's come back to me and presumably there's like a URI fragment that has the token or whatever value I'm interested in obtaining and then I can get rid of showing the web view. that's like, Xamarin .auth did that a bunch. and, and of course the problem with that, and it took years for like Google and others to really try and stamp out, you developers from doing this and they probably still haven't fully, cause it is kind of hard to detect every scenario that does this. Right. But if you haven't figured out some of the problems with doing it this way, right? Like, okay, I have an app, I'm asking you to log in with your Google account in a web view. that I can inject JavaScript into. I might steal your Google password. Thanks. Right. so, so like that, that, know, very reasonably quickly became a, shouldn't do this. Not that people listen to that advice quickly as well, but you know, Xamarin auth eventually kind of went away. One of the reasons being it was like founded on doing this as part of your flow. And it's just like, no, you, can't have our customers doing that. Allan (30:20.524) Yep. They've got clever ways of doing it, that's for sure. Jon (30:43.79) We, and, and, because also like our customers, customers are still our customers kind of too, right? So we don't want to like enable developers to do something that's going to be harmful potentially to their own customers. by proxy, know, we've, we've enabled this, right? So, enter Xamarin essentials where we, figured out like, okay. Well, there's different ways to do this. iOS has an API. and there are several APIs that they've changed over time that allow you to basically say, I need to start an authentication flow. Here's the URL that I want you to go load up for the user. And they will do that in like a, you know, separate kind of instance of the browser that I don't have access to in my app. That's kind of the foundational feature, right? So as an app developer, there's no way for me to inject JavaScript and spoof your, you know, your get your password and username and collect that or anything like that. And I'm going to also give you the callback URL or URI, I guess more accurately of when that flow hits this URI pattern, you know to come back to me. And so you kind of gave it like those two pieces of information and then off it went and showed the user the thing, the user did the flow and. eventually maybe if it was successful, you got back the pattern and the URI that they called back to and you could parse it and get the information you wanted. UWP had, you know, basically the same API. Android was the weird one out, but it still kind of worked that way. and, and Chrome custom tabs and that was, yeah, there's a bunch of different iterations of it too. And, and, but you know, both of those platforms and UWP too. Allan (32:22.76) What's it? It's Chrome TabClean or whatever now. Allan (32:28.854) and things of pain in the earth. Jon (32:35.088) kind of relied on the fact that like they could validate and know your app was the only app that was allowed to handle that, that URI pattern, right? Otherwise, like I could go build an app that handled, you know, whatever custom scheme too, and hope that somebody, you know, launched a flow and when you, on the Android, you know how it pick, like, let you pick like, which app do you want to handle this intent and be like, let's pick that one. Yeah. Allan (32:46.22) Mm Allan (33:01.846) I don't know. That one sounds good. Jon (33:04.248) Yeah, nefarious sounding, you know, duplicate of this app. that was, you know, part of it too. and then, yeah, UWP had the same thing with like packaged apps and stuff, but now enter Maui and we don't, we don't have that everywhere anymore. We, still have it on Android. We still have it on iOS, but windows when app SDK actually does not, it just doesn't work. Like those APIs exists still because they came from UWP. But if you call them, it just like, Allan (33:07.664) Ha ha ha. Jon (33:33.336) it throws exceptions and stuff. Like they just don't work. so we've had this constant. yeah, I know. I mean, part of it is like, because when app SDK doesn't have to be packaged apps. And so there's like the way that they figured out like single instancing of the app and sort of like ownership of things, for like registering hand, protocol handlers and stuff. Like it just doesn't map correctly to unpackaged. Allan (33:37.494) I have no comment because it's Windows. Jon (34:01.306) By default, mean, not saying that they couldn't figure it out on windows, surely they could. So it's been a kind of renewed area of interest of like, what are we going to do with the windows stuff? And, and, know, it's a cool thing from the perspective of it's a hard problem to solve. And it's kind of fun to try and think of how to solve it. But so far, the unfortunate reality is there's not really a great one solution to solve it. There there's some, and we'll have to put them in, I guess it's a community links projects or just, you know, whatever section, put it in the show notes, like Dot Morton has kind of his own take on it. There's a few other people that have kind of done similar things and there's different suggestions of like, you could start up, you know, your own local web server. could use embed IO and set up your callback server with that, which might work in some cases. Or, you know, maybe your, your corporate machine policy doesn't allow apps to open ports and it doesn't. Allan (35:00.736) If not, something will block it. Some firewall in front of it will get in front of it. Jon (35:03.054) Yeah, something will block it or like the, the authentication provider doesn't allow you to specify local host as a pattern of your callback URI. That's, that's something that can happen. Not all of them do, but some of them do. so there's all these different like reasons why that might not always work. It's not a, you know, one size fits all solution. on, on windows, you could, you can still do like the whole protocol handler callback thing. but kind of similar problems. one like, okay, how do you know that that's the right app for it? guess like, I think only one app can register. But at the same time, like Windows doesn't, Microsoft doesn't like enforce like, yeah, you own that scheme and we're good. And we're only going to open your app that uses it kind of stuff. So, problematic there too. and then there's the whole thing of like, you know, man in the middle type attacks and though you've got to make sure you send like state objects around. And that's sometimes not even really enough to do it properly. So, It's been a cool, frustrating, still not found a solution yet. So I am kind of curious too, if there's any listeners that have ideas in that area. I feel like there's not anything too new to learn yet, unfortunately, but maybe I'm wrong. Let me know if I'm wrong, if you have a suggestion. Allan (36:23.874) Well, you got to figure there's apps out there kind of doing this stuff, right? Like like VS code, for example, you hop out of the app and it, you know, it says click here and hop back to your app and. Jon (36:29.284) Yeah. So. What I always have kind of, well, and yeah, so the way that a lot of those apps will do it is kind of the polling thing, right? So you might launch the authentication flow and it, but your auth provider has to support this scenario where it's like, okay, I logged in and now my app is pulling the provider's URL with some session information or whatever. And keeps asking it like, you received the authentication yet? So I'm contacting them instead of them calling back to me essentially, right? So that would be a way to do it. But again, I don't know if everybody is super happy with that flow or if it'll even work for the provider yet that they're using. Probably some of the big ones like Google has the device off flow kind of thing where they do that. Others do as well, but maybe it's not universally used either. Allan (37:11.852) Yeah. Allan (37:20.086) if it'll even work for everybody's flow. Allan (37:35.416) So that's what you've been working on. Window stuff. Jon (37:37.444) Yeah. Windows stuff and the other Windows thing and not me working on it, but we talked about collection view handler two for iOS the other week. I don't know that it'll make it for net nine, unfortunately, but we're kind of doing a similar thing for Windows as well. So yeah, there's a lot of interesting things going on and that was that's another member on our team, Mike, that is working on that. And we should see some stuff coming in the future for that. All good stuff. Allan (37:49.08) Yep. Allan (38:07.724) It'd be nice and fast. Not that I build Windows apps. Jon (38:09.658) What's that? Yeah, nice and fast and just work better using newer APIs that weren't available when we did the original implementations of things, Allan (38:20.399) when UI has come so far, I don't want to say that. We'll cut that out of the episode. Don't get yourself canceled, John. Jon (38:26.978) One, two steps forward, one step back, let's call it. Yeah. So. Allan (38:34.656) Alright, so normally this is why I think your jingles are right because this is what this is our section where we're to do the Tales from the Crypt. We did an episode on this. I don't know. I want to say a couple months ago. And it was about kind of some of the dark things that John and I have had to witness myself as a consultant. I've gone in and seen some doozies. You know when John gets a support case, I'm sure you've seen some fun stuff. Jon (39:00.506) Yeah, there's things that are special. Allan (39:05.038) And sometimes they're not meant to beat up on people for sure. Sometimes it's a case of knowledge and sometimes maybe I am trying to beat up on some people because they thought they knew better. Jon (39:18.158) Well, yeah, I mean, you know, listen, we're, we're all, I think we all want to, to, to make sure that we are able to learn and grow in our careers and what we do. Right. And so I, we were both, you know, much junior developers many years ago too. And I made tons of really stupid decisions and mistakes that, know, current me would be like, what the heck are you thinking? Like that was really, really dumb. Allan (39:29.837) Yes. Allan (39:35.712) Exactly. Allan (39:45.236) Learn from those who have made more mistakes than you have. Jon (39:49.078) Right. And, and, and a lot of this is, you know, stuff that I think you and I both see often enough that it's worth calling out and talking about it. And yeah, we can poke a little fun at it being like, you know, what are you doing? Like, don't, don't do this. Right. And we'll, do that because what else? Like nobody wants to listen to just say, this is the best practice, right? We got to have fun with it. Allan (40:13.484) No. Well, unfortunately, I can't do do you remember the show The Tales from the Crypt with a guy that I can't do his voice and it probably sound like screaming into the microphone. Like I said, if we get into Yoda or something, then fine, we'd be good. But I can't do his voice. So we might rename the section. But this week, the fun part is, is that I think I get to beat up on you a bit about this, John, because I'm pretty sure we talked about this recently. Jon (40:18.34) Yeah, yeah, yeah, yeah. Nah, me neither. Jon (40:26.958) Yeah. Jon (40:31.332) Mark, Jon (40:36.758) good. Yes. Allan (40:38.843) That's why I posted it first because I wasn't gonna make fun of anybody even though I have seen people doing this. But I know well that's that's how it goes. Jon (40:40.943) buried the lead. But no, I mean, you're right though. And like, think that if you found, I'm sure you, they're not hard to find things that either I personally wrote that are really bad. That's a good example of the like, everyone does it. Let's just figure out how we all improve from it, Allan (41:03.757) Well, this one is this one is true because a lot of people don't do it. A lot of big businesses don't do it. And that's fine. And at least you're not doing dot get result dot wait. If you're waiting a task in a mobile app, bad things are going to happen. Just don't do that. I am going to make fun of you if you do that. So so far. Jon (41:19.4) I mean, yeah, I've, I've, I've probably done that. I probably have code somewhere still that does that. I'm sure. know, why either I knew better at the time and did it anyway, or, you know, I really didn't feel like figuring out how to get out of the situation that I wanted to use it in. Allan (41:25.622) Okay, I haven't caught you yet, but I will call it if I catch you. Allan (41:39.81) So there's always a situation you can get out of that. So don't hear John on this one. Don't do it. Don't do don't do result. Just don't. Fair enough. I know what you're saying. So the specific topic in the roundabout way that we got to it is cancellation tokens. I either see most apps don't use them. John. Yeah, he knows do. We talked about this already anyways. Or they simply abuse them. Right. So Jon (41:43.088) I know there is, it doesn't mean I wanted to figure it out. That's all I'm saying. Jon (41:56.901) Hmm. Allan (42:10.338) they're canceling all the time or you know, they're canceling when they don't need to or they're not canceling them at all. Right. So they a lot of times even today too I see people put cancellation token dot none who cares let it run off into space. So in a mobile app it's not the end of the world but a lot of tabbed apps you know if you're swapping between tabs constantly you start really loading the guy up right. Jon (42:24.228) Yeah. Yeah. Allan (42:37.729) And chances are when you come back to that tab, if the data is old or didn't finish loading anyways, you're to call fresh load again anyways. So don't let it finish if it's not, if the user doesn't even care, just cancel it out because what can also happen too is if the, let's say the page went away or something, you know, can start calling out to other things like render this UI. And it's like, there is no more UI dude. What are you doing? Jon (42:51.023) Yeah. Jon (43:00.592) Yeah, yeah. I was going to say like that's, that's one of the, you know, side effects that's going to bite you if you don't kind of think this way, right. As you might end up trying to do stuff and causing crashes that are kind of hard to figure out why they're happening sometimes in a production app when it's something as simple as like, well you're that request, you know, finally finished, but you already moved on and now it blows up. Allan (43:24.972) Well, I mean, it's gotten better now because you guys are very strict about killing the binding context, like splitting it off right away, right? So no matter what things get it now, not in tabs, but certainly when a page is, is destroyed, I'm pretty sure one of the very first things you do is binding context is null on the page. Now start cleaning up all the junk. So there's nothing left. Jon (43:44.409) Yeah, there's more stuff coming by default. think we talked about that last time too, right? Like where we've taken a more opinionated approach coming, you know, going forward. but yeah. Allan (43:50.68) Yep. Allan (43:56.824) But in any case, if the view model continues to run its stuff, it doesn't matter. It's yelling into an echo chamber at that point. But you've used that memory. You've tried to call out to things that are now just kind of yelling into the trees falling, but nobody is there to hear it fall in the middle of the forest. So. Jon (44:08.985) Mm -hmm. Jon (44:19.268) Yeah, or like you're duplicating, you know, some event that gets called that shouldn't, doesn't need to be, you know, best case you're like just doing more work and using more resources than you should be. Allan (44:24.087) Yep. Allan (44:29.674) Exactly. So what I try and tell people to do is there's two points where you want to cancel depending on what your workflow is. One is you want to cancel it when your page is going to the background. Right. You can always reload it when they come back. Chances are you're going to anyways. Right. So if the page goes to the background and there's another page on top of it just cancel it out. Right. It's no point. But certainly if the page is being destroyed so like a disposable Jon (44:54.116) Yeah. Allan (44:59.096) type event, that's like a cancel everything. The page is dying. If there's something running, it doesn't matter. Again, it's yelling into an echo chamber. The echo chamber doesn't care. You can scream in there all day and you only hear yourself just like in John's room right now. They only hear his echo. If you yell, only you hear? Jon (45:06.692) Yeah, that's not gonna happen anyway. Jon (45:19.088) I mean, there's other people in the house currently, so they might too, but I would hear. Yeah. Allan (45:22.36) They might hear you. Fair enough. So use the cancellation tokens. They're there for a reason. They can do you a lot of good. It's very easy to put in your base view model. I've seen some people use lists of them. You don't need to do that, right? You really don't. Pretty much all the async tasks are. Jon (45:42.084) So you're kind of saying like create one for your view model essentially and then have everything check it. Allan (45:46.959) Yeah, just use one. Right, because what are you going to do cancel like all 60 of them? If you've got a list, just just cancel the one and then they all go because they're all now useless, right? They're all null and void. Cancel them all and move on. Use cancellation tokens. They're good. Jon (45:53.73) Right. Yeah. Jon (46:04.644) So, know, the one thing that I know I always kind of feel too, like, yeah, one per view model sounds like a good idea. I think the other, yes, the other thing that I always find is like, that's maybe good for that, like layer of your app. If you have, you your services and stuff, like that, obviously they need to support, like accepting a cancellation token, right? If I've got a call to my web API, I'm gonna need to... Allan (46:12.482) That's opinion based, obviously. Allan (46:28.579) Yep. Jon (46:34.212) take that into consideration, which isn't that hard to do. But one of the things that I think maybe why people don't do it as much as they should is like, it's one of those things that kind of permeates like the whole chain of everything you're, you're, you're hitting code path wise, right? Kind of like async, right? You know, it's like, Allan (46:51.2) Well, the general rule when you do async though is you've heard the term async all the way, right? So that's like the task all the way through, then all the way back. So I think when that's implied, it also means also pass the cancellation token. If you're feeling lazy, stick a default on it and let that go through. But somebody has to pass the cancellation token. So presumably from the start all the way through. Jon (46:56.769) Mm Jon (47:01.732) Yep. Yep. Allan (47:20.471) And if you just went with cancellation token none or the default, so be it. It just flew into space, you still just async all the way and include the cancellation token all the way. It's not hard. Jon (47:30.382) Yeah. And that's, that's kind of what I'm getting at, right? Is like, you know, almost when you're, when you're building these APIs and stuff, like stick it in there. All right. Like you said, if, you don't use it from whatever's calling it right away, at least in the future, if you fix your mistakes, you know, it's not as hard to do that. Allan (47:33.507) Yep. Allan (47:47.276) Well, and the funny thing is, is if you're generating any of your APIs right through Swagger or NSWG or Refit or Kyoto, if you're using that unfortunate thing, then it puts the cancellation tokens in that generation pattern anyways. So they're good. Don't be scared of them. They're friendly little guys. Jon (47:52.719) Mm -hmm. Jon (48:05.464) Yeah, so you've already got it. Jon (48:09.594) They are pretty handy. And I think we've gotten better APIs over the years in .net too to like do other things with them, right? Like I feel like it used to be difficult to, what was it, like do like timed, know, cancellations and stuff like that. There's like all the different cancel after, yeah. So that stuff's all gotten quite a bit nicer. Cause I know I've done some stuff where I've, I can't recall the exact scenario, but where I'm like, I want to like, Allan (48:25.762) Yeah, for timeouts. Right. Jon (48:38.16) tie these things together so that when this condition occurs, it's gonna fire the cancellation, but if it doesn't occur by such and such time, I want it to fire anyway and all that kind of thing, right? So there's some pretty cool stuff you can kind of wire together with them as well, if you just start thinking that way. Allan (48:55.736) sufficient. Yep. So that was it. That was my tales from the crypt. I see John's got one coming. Let's hear it. What really grinds your gears? Jon (49:03.298) Yeah, I've got one today. So, you know, again, in, in, in the spirit of, of, know, trying to like do things in a way that's going to help yourself be successful, right? you know, one of the things we see time and time again, and this is what I was saying earlier is this, this kind of learning opportunity is more about the, we keep seeing this. Like why, you know, one question when we see patterns over and over, it's like, well, are we doing something wrong with how we either document things or show samples of things or build the API around things. Is there something we can do better from that perspective? Probably, and we should be digging in and learning those things. one pattern I see over and over again is, well, two common things. They're separate, but they're similar. One is putting collection views inside of collection views. So like if you have a... a collection view and it scrolls vertically in your data template, in your item template, you might put a another collection view that scrolls horizontally, right? Right. And, and you know, like, this is why I kind of say like, well, maybe, maybe part of it is we're not giving the right kind of information around these scenarios, right? Like that actually might be a valid thing to do. Allan (50:13.72) Like Netflix. Allan (50:17.463) I can't do that. Jon (50:29.978) there are some scenarios that I could imagine that maybe that's okay to do. It's still, I'm still gonna err on the side of saying like, probably not. Like, you really have a view of data that is like an infinite scrolling list of vertical, know, scrolling list of horizontal collections of things? And if you do, is that the best way to display your data? Allan (50:54.242) Well... Allan (50:58.222) Technically, technically, it's not infinite scrolling horizontally in Netflix anyways. It's like a carousel of repeated. I you get about what about 20 items? Well, you've done come on, you've done the Netflix. You've done the Netflix scroll like now, now, now. Right. So eventually it's like, okay, dude, you said no enough times. We're starting over. Jon (51:12.75) Yeah, it's not infinite, yeah. Jon (51:19.95) Yeah. Yeah. It's the same in, what app? guess it's like, yeah, maybe it's Netflix. Maybe it was like Apple TV. I'm thinking of two where I'm like going through shows. Yeah. It's like, it's not, not ever infinite. So one, yeah. And I don't know if that's better or worse in this scenario necessarily. Like in, in, some extent, if it's enough items, it's still may as well be infinite. You know, like if, if you've got Allan (51:28.534) they all do the same thing now. Here's category 20 shows, infinite carousel. Jon (51:48.56) like 30 items, that's still, if I was going to hard code 30 views, like 30 instances of the thing I'm showing, is that going to be lighter than loading five up and then potentially loading more or reloading stuff as I go? It's hard to say. this is part of my, I guess my, my tail here is like, it's not always obvious, like what the right answer is either for these situations, right? The answer could be, a combination of maybe we shouldn't do it this way, right? Like, is there a different way to approach the situation for the user interaction? If the answer is no, we must absolutely do it this way. Like, okay, well, you know, yeah, start thinking about, what if we limited the number of items in each section? Even if it's like an idea of like lazy loading, right? Like maybe that's a way to go is you've got five and when you reach a threshold, you know, scrolling through them, maybe I add more if the user did that, but most of the time the user is flying through the list and isn't going all the way over. So maybe I don't need that heavy of an approach on every single vertical item, right? Like there's different ways you can think about doing it. And so. Allan (53:05.406) What about a vertical collection view within a vertical collection view? Jon (53:11.8) so that falls in the territory of no, don't. Allan (53:18.082) know which one's scrolling. Jon (53:20.3) Yeah, well, this is the problem, right? If you actually try and do that, like on iOS, if you nest two of those together like that, it's, it's chaos. Like I think it might crash or it might just not work how you want it to. It's. Allan (53:31.242) It doesn't crash. tried it once for fun because I had seen it and it was crazy. I was like, can you fix this? No. No. It's got scroll region that's trying to render to some height and it's just like, you can have this space. Good luck reading anything in it. It kind of makes it all squished and well, it's crazy. Jon (53:37.998) Yeah. And no, no. Jon (53:45.176) It's not fixable. Don't do it. And same goes for like. Jon (53:58.948) Yeah. Well, that kind of goes for like scrolling things within scrolling things, right? Like never nest a thing that scrolls within another thing that scrolls of the same orientation. Just don't do it. Allan (54:00.632) Don't do it. Allan (54:11.928) The web does it all the time though, John. Jon (54:14.56) I know. Well, so, but here's the caveat though. The way the web would do it is, I mean, you've got constraints on the size of the thing that scrolls within the thing that scrolls, right? So like in theory, you could put a collection or you could put a scroll view within a scroll view if the inner scroll view has a fixed, you know, height of or size of the direction of scrolling, right? Allan (54:25.496) Yeah. Allan (54:36.512) I also didn't say that the web did it well because if you've ever hit the point where if you've got an infinite scroll, what happens is you scroll down and it hits that new scroll bar and it starts scrolling through that and you're like, no, no, no, I want to scroll further. Jon (54:39.352) Yeah. Jon (54:49.272) Yeah, and then you gotta find the right place to like touch just enough to scroll back out of there so you can keep, yeah. Allan (54:54.286) And everybody's got those like invisible scroll bars. Now it's not like the old days of the gray ugly thing that's still there. It's got to be pretty and hidden when you're not scrolling. So you're like, bring that stupid thing back up. I want to scroll on the big page. So. Jon (54:58.07) Mm -hmm. Yeah. Yeah. Jon (55:07.332) Yeah. And, and on the, the, you know, final note of this one is like collection view inside the collection view and also almost the same problem, slightly different, but pretty much the same bindable layouts within, you know, a collection view. Like if, if you're, if you're data binding some virtualized or not virtualized even some list of, you know, things within a list of things, you're, probably asking for a little bit of trouble. So, you know, in this case, like, The one that I, and I might've said this one on our last episode too. It's like, okay, I have a data template for my collection view. And then I have a bindable vertical stack layout inside that data template because I might want to show one sub item and I might want to show a thousand sub items. Well, you again, first of all, is a thousand, like what's your, what's your actual limit? Like Do you think it's a good experience to show a thousand of them sometimes and one sometimes if you do, then maybe like you're, you're doing the list the wrong way. Like maybe your actual item type is, you know, an item and, and you've got to do a data template selector and figure out like, you know, I have a, I have top level item that has a thousand sub items. Well, maybe I need to kind of figure out how to logically collapse those so that like they're all items, right? But they're different data templates, something like that. so that I'm recycling, you know, the sub item data template instead of trying to squish it all into one item template. I know it's a lot of item templates. So there's that, right? You could do it that way. But the problem is like, if you're doing bindable layouts, every time the binding context of that cell, that is the parent of them changes, we don't necessarily know what you want to do. So we got to just recreate everything. So if you've got like, you know, a bindable layout, is showing, I don't know, a bunch of labels and images and stuff in each one of its item templates. We're going to recreate that whole thing. The moment that you change the binding context. So for every new item, you've, you've kind of just taken away your ability to virtualize and like recycle these things, right. in, in a sense, cause you're, you're not saving yourself the view, inflation time, basically. Allan (57:31.406) So I have done the Netflix lookalike as a challenge and it was a collection view, virtualized collection view of carousels. Now collection view going up and down carousel was 20 items and I was able to obviously the carousel view needs a you know a width to defined otherwise it's like right so by giving it a height I knew the height the height was the same for every cell. the width was the same for every cell. It didn't have any problems with it. It just kind of did his thing. Yeah. Jon (58:05.668) Yeah, and it can be done that way, right? It's more like, and this again, it's not every scenario is going to work the same for you. like at the end of the day, you kind of got to figure out how to help yourself and understand what you're doing so that you know where to look for the problems when you run into them. Allan (58:25.666) Well, normally if the collection view is going to be a problem for you, it's when the cell sizing changes because everything changes with it, right? It forces everything else to recalculate. When you're saying this is your place base, that's it. Just do your thing here. It doesn't generally tend to choke. And if it does, it might be one little blip as it loads. Jon (58:46.296) You, you might've been okay. Yeah. Yeah. Like you, might've been saved by like part of it is like how things get recycled on the native level. Like for iOS, in the past, we had some, some bigger issues with how data templates were recycled. like you, like you said, if you're not changing the size, like you might, my main thought is okay on your carousel view every time. every time the item, the binding context for the parent data template. So the data template for the vertical scrolling thing, right? Every time that changes, it's going to then change the, the item source on your carousel view. And at that point, essentially recreate all of the cells in that carousel view. Now you might get lucky in the sense that, because like you said, you kept the sizes and stuff the same. Allan (59:24.696) Yep. Allan (59:30.306) Yeah. Jon (59:44.656) that it might have some of those in kind of the recycle bin to pull back out and use and be able to just reuse them. I'm not 100 % sure, but knowing a little bit about how that code is implemented, I suspect you might get performance benefit from that, which is kind of a cool thing. Allan (01:00:00.576) And the thing is that we didn't, there wasn't anything other, the occasional blip if you were trying to turbo scroll, but you just don't really do that. Right? So you'd scroll down. Okay. Sometimes you'd see a load. The only problem I ended up having was I had to preload the images in the carousel because the carousel, wouldn't, it wouldn't make the call for the image until the image was viewed. So that was, and I was like, yeah. Okay. Cause I got to go and get it. So all I did was, okay, get the data. Jon (01:00:07.288) Yeah. Jon (01:00:21.404) Mmm. Allan (01:00:28.918) Start putting there, but start preloading, start forcing all the images to load right in the background. So when it gets there. Jon (01:00:33.68) So, cause the images wouldn't load because the cell hadn't appeared yet. So it didn't know to even ask for it. Okay. Yeah. Allan (01:00:37.293) Yeah, so didn't know to actually go out and call. So you had to wait for it to call and then the image to load. Now it was usually pretty quick, but you know those product people, they're like, you know, Netflix does it right away. Okay, well, we can do it right away too. We just got to do some extra stuff. No problem. Jon (01:00:52.622) Yeah. Yeah. And you know, at the end of the day, I would love for all those scenarios to just work super well out of the box. And that's, that's always the goal, but you know, we're not, that's not the reality. Allan (01:01:02.434) Well, FF image loading. just take out an image service, you tell it, here's an image, go preload this, and then when it gets there, it's already, I've seen that URI, here it is, this image is already here, It works great, piece of cake. Jon (01:01:14.596) Yeah, exactly. So that's my, that's my, my tale from the crypt. Allan (01:01:20.172) your tales from the crypt? All right, well... That was a good one. Jon (01:01:25.614) I think that might do it. So you did mention before embed IO. that is our plugin package and product of the week. Allan (01:01:30.924) Yes, it's pretty old, but it's still very relevant. It works with newer .NET. Yep. Yeah, it's been fantastic. It's a little... Jon (01:01:37.852) And it works fine on Android for you and iOS. What are the rules on iOS around hosting? Allan (01:01:46.55) No background, which is fine. Right. This one's going to have a keep alive anyways. Right. Like keep the screen on. Right. Because it's a kiosk. So it doesn't matter. Right. So no big deal. It is what it is. I mean, I don't know if you remember back in the day they used to have those little you you wanted to bring a Web key or a storage. So you turn your phone into a Web server and you could upload and download files. Jon (01:01:48.592) Right. Yeah. Okay. Jon (01:01:54.35) Yeah, yeah, kiosk mode the app will always be there, right? Jon (01:02:10.391) Mm Allan (01:02:14.85) through just like a website on your phone over Wi -Fi. So that was pretty cool. They don't, you never see those anymore. Jon (01:02:16.046) Yeah. Yeah. Yeah, well, some like, yeah, and like emulators you do sometimes, especially on iOS and tvOS, right? Cause they're like, I don't, how was we gonna get the data on there? They just launch a little server and you go to it and upload. Yeah. Allan (01:02:25.065) that's... Allan (01:02:31.79) I forgot about that. Yes, the emulators. We're not supposed to talk about those things, though, John Loser. Jon (01:02:38.32) They're okay now, right? For iPad. Apple allows them now. Allan (01:02:41.324) Well, no, but... to make the games. Jon (01:02:46.862) Well, yeah, of course. If you haven't seen like the, think it's Delta is the app. It's like, it's pretty slick. It's pretty nice. I'm waiting for the TVOS one, but I think there was a reason why they haven't gone there yet. I forget the reason, but I was like, that makes sense when I read it, but that'd be great. Allan (01:02:48.252) Hey, Allan (01:02:54.274) Yep. Yep. Allan (01:03:05.869) I've just been signing my own for years. I'm still signing my own. I just have to do it every every year. And then when you do it, usually you have to reload the app, which means you have to download all the ROMs to it again. That's so anyhow. Anybody that's thinking about writing an emulator or anything, check out embed IO. I think it's more at the dot net standard level or dot net like base dot net level, so it just works with pretty much everything. Jon (01:03:08.942) Yeah, I did that too, but it's such a pain. Ugh, such a pain. Jon (01:03:19.095) Exactly. Jon (01:03:26.062) Yeah. Allan (01:03:33.819) I'm using it on Android and iOS successfully right now. It's pretty cool for allowing like a website without interop because interop can be no offense to the web view in Maui, but it's just a difficult thing. But if you can call an API that's right there on the device, you can call native code right there in your API. That's pretty rad. Jon (01:03:55.428) Yeah, that's a cool project. It's one of those ones too that I'm like, I almost could expect that to not work on Android or iOS. Like there's so many things that could just have gone wrong and using like the .NET APIs and stuff there because it's just not a scenario that's like well tested or used, I think. But it works. Allan (01:04:14.222) I'm not sure if you can open these to to more than local hosts now, like if you can open it up to a Wi Fi network. But that's obviously not my test case. Anyways, I tried it just for this one and I was like, cool. Yeah, this is good. It's good. Jon (01:04:18.83) Sure. Jon (01:04:26.98) Yeah, it's nice. All right, well that is the pick of the week. That'll do it this week. Be sure to head to our website, gonemobile .io. We are on YouTube again, sorry again. Like and subscribe. Actually that was one of the other feedback notes is that, I joked about it, right? Like searching Gone Mobile on YouTube and it's like some dude in a van. So somebody had mentioned too, like, it's not really that easy to find the channel. So I added a whole bunch of links to like the website and I went back and added some links to the YouTube video on like the show episodes on the website too. So maybe that'll help our SEO type stuff too, you never know. Maybe we'll actually be seen. So if you're looking for the channel, go to gonmobile .io, the link is on there in a bunch of spots. I'm sure you'll find one of the spots that it's on. Allan (01:05:21.602) follow our excrements and then that way you can you can tell that we're what we're doing. Jon (01:05:24.73) Yeah, go on the X and the Twitter and the other places if we remember to post them and give us those five star reviews on the Apple podcasts or Spotify or, know, I don't know what all the platforms are these days. Those are the two I know. So take them. All right, we'll see y 'all later. Thanks, Alan. We'll see you listeners next time. Allan (01:05:41.891) Nice. Allan (01:05:46.296) Have a everybody.