Elm Town 56 – Why don’t you do it in Elm?

MAY 16TH, 2023
|
50:01
Théophile Kalumbu comes by to talk about how Elm makes developing a frontend fun, building a design system explorer, iterating quickly, and getting Elm to production.

Details
/
Transcript

[00:00:00] Jared: Hey folks. Welcome back to Elm Town. I'm your host, Jared Smith. We'll be visiting with Théophile Kalumbu today.

[00:00:15] Sponsored by Logistically

[00:00:15] Jared: But first, let's talk about our sponsor. Logistically is the company where I work. At Logistically, we make transportation management software for third party logistics companies and shippers. I'm grateful that Logistically pays me to spend a bit of my time recording Elm Town episodes, as well as pays for our recurring production and hosting costs.

[00:00:34] We build the front end for all new features in Elm. We have over 100,000 lines of Elm code in production. We're always eager to talk to folks who enjoy writing Elm. Please drop us a line, elmtown@logisticallyinc.com. I'll put a link in the show notes.

[00:00:56] Some of Théophile's contributions to Elm

[00:00:56] Jared: Now, Théophile Kalumbu. Théophile has a few Elm contributions I'd like to mention Elm UI Explorer, which is a tool to showcase a design system in Elm.

[00:01:10] He gave a talk about it at Elm Europe 2019, called "Building a Design System with Elm". And then recently he talked about Elm on the French podcast, If This Then Dev. Théophile, welcome to Elm Town.

[00:01:24] Théophile: Thank you, Jared. Hello.

[00:01:26] Jared: Hello.

[00:01:27] So. Good. Good. Uh, I wanted to ask you, did I pronounce your last name correctly? Kalumbu.

[00:01:34] Théophile: You pronounce it correctly? Yeah.

[00:01:37] Jared: Okay. All right,

[00:01:38] Théophile: great.

[00:01:39] Jared: I always, uh, am afraid I'm gonna make a mistake there. Uh, is that Zambian, you said,

[00:01:45] Théophile: Yes, actually it has, uh, origin from Zambia. Uh, my father is from Zambia, and, um, I, I'm, I've been raised in France, uh, and I, uh, I live here in Paris.

[00:01:58] Jared: All right. And so did you grow up in Paris?

[00:02:01] Théophile: Uh, actually, I, I grew up in eastern France, uh, in a city called Belfort. So it's near the German and the Swiss, uh, border. Uh, and I, uh, I came to Paris, uh, when I was 20 to pursue my career as, um, Programmer, uh, because, uh, I joined a school called , uh, here in Paris where I, I started, uh, working more and more, uh, on the, on the web, and I found my, my passion, I say,

[00:02:33] Jared: Okay. Excellent, excellent.

[00:02:35] Finding passion in programming through Nintendo games

[00:02:35] Jared: And so, you found your passion, but tell me a little bit, let's go back and tell me kind of your start of how did you become interested? How did you find out that it was your passion? Was this, you know, when you came to Paris or did you realize this some at some point earlier than that, and then, um, and then go to Paris to pursue that?

[00:02:54] Théophile: Yeah, so, uh, when I was a kid, I really appreciate. Uh, playing video games. So it was, uh, you know, in the nineties and I was a fan of, um, Nintendo World. So I've played, uh, Mario and then Zelda and all those, uh, great games. And on the other hand, I, I really enjoyed drawing when I was a kid. Uh, and I always wondered, I wanted to create, uh, things, uh, digitally, but I could not serve.

[00:03:24] Uh, named them. And, um, I, uh, when I, uh, grew, I had many, uh, let's say, uh, computers and then I started, uh, hacking a bit and drawing and discovered Photoshop. And, um, uh, fortunately in, uh, the region where I grew up in Belfort, there is a university, uh, specialized on, um, uh, communication. And, uh, it, uh, so I applied and I was able to, to, to be able to, to learn news media there.

[00:03:58] And this is where I found my passion.

[00:04:00] Jared: Okay. Wow, that's really neat. Yeah. It seems like, uh, a lot of us are, are interested in games and then, you know, find our way to programming through games. Did you, uh, write any games through that

[00:04:15] Théophile: I. I, uh, I wrote games during, uh, when I was learning flash, uh, previously, uh, it was a flash. Macromediazzzzzzzzzzzzzzz was, uh, something very, very powerful at, at that time. Uh, but no part hacking with, uh, tool called RPG Maker. I don't know if you know RPG Maker. Uh, there was this, um, this, uh, application. We were able to create your own role game.

[00:04:44] Uh, kind of, uh, you can create your own Zelda, something like that. And I, with my friends, we are, uh, creating the sprites and, uh, doing a bit some codes to, to make it work. And it, it started like that a bit, this, uh, curiosity for coding. But apart from that, I haven't been, uh, able to code the serious game, let's say in my career.

[00:05:07] And I'm sorry.

[00:05:08] Jared: Oh no, that's, I don't know that a serious game is, is is much fun anyway. Right. You know, the best games are the ones that are made just because you're having fun. I think so. Um, yeah. That, that's great. And so, um, you developed this passion and you. Came to Paris at age 20? Correct. Then at what point did you discover Elm?

[00:05:36] How did that come into your view?

[00:05:38] Théophile: Um, it actually, it can, I would say late, uh, during my career because I, like many people, I, I started coding, uh, in JavaScript mainly, uh, and PHP uh, had, uh, let's say a big, uh, impact here in France especially. Uh, thanks to, uh, frameworks like Symphony. Uh, so I have, and I've always worked, uh, at the beginning in, uh, startups or, uh, communication companies where we had to build, uh, websites and, uh, engaging experience with Flash.

[00:06:19] Again. Uh, so it was more, uh, let's say, uh, object oriented, uh, program programming that I was using, uh, at the beginning of my career. Uh, and I discovered m later, um, it was in, uh, 2017, uh, even 16 before when I, uh, I was the lead developer of a company called OuiCar, Um, and this company, uh, was specialized on, uh, car rental. And, um, I met, uh, that guy called Guillaume Claret when a friend of mine was really into functional programming. And at the same time, React was popping everywhere when Redux was. The way to go and I accidentally or randomly found, uh, m by talking to my friend and looking for a solution that will allow to build ui, uh, in a reli reliable way.

[00:07:31] Jared: Sure. Yeah, that, uh, sounds familiar to me as well, you know, coming from a JavaScript front end background and then, and then looking to find a way to build a reliable front end. um, What was the moment when you had discovered Elm? That it became the, the solution to the, you know, to the problem of that reliability and, you know, and, and, uh, you know, whatever other struggles you faced.

[00:07:59] Théophile: yeah, it, it started at home and not at work because, um, It's something I, I, I, I just noticed with this, uh, Elm ecosystem, it's very hard to, to, uh, to ask or to be able to, uh, persuade, um, teammates to go for Elm because we are used to do things in the mainstream, uh, way. So at home I started harking with Elm and I was doing side projects.

[00:08:29] And the one thing that really, um, surprised me with Elm is that when I was building programs, it didn't crash cause I had this continuous, uh, discussion with the compiler. And I was able to just write codes. It was very late. I remember, uh, I think, um, my first daughter was, uh, one years old or two. Uh, but, uh, at that time, uh, children don't sleep, uh, very, um, let's say, uh, early or wake up.

[00:09:07] So I was awake very late, and when she was sleeping, I started just hacking some element. I found it very wonderful to be, to be honest.

[00:09:16] Jared: Ah, yeah. That's great.

[00:09:20] Learning functional programming through React, then Elm

[00:09:20] Jared: And so did you have experience with functional programming at this point before you, or when you were getting started with Elm?

[00:09:27] Théophile: Never, never before. The, the only, let's say, um, view of functional program I had was through React, uh, because at that time we are building, uh, enterprise application with React and React, uh, borrowed many concepts from functional programming. Such as functional components. Uh, and when you use tools like credits, we have these reducers that are pure functions, uh, and many concepts immutability also.

[00:09:56] So, uh, this is how I entered the functional programming, uh, little World was through React actually. And, uh, each time we were. Following strictly those rules, uh, not mutating variables or stuff like that. I saw that we had less much bags than. We used to have. So I was like, Hmm, this is interesting. I think there is something to do there.

[00:10:25] So this is how I entered the functional programming role. And then I entered, let's say, officially into functional programming through Elm, where I learned, uh, all those concepts, uh, much, uh, much better.

[00:10:39] Jared: Sure. Yeah, I think it, it definitely, uh, lends itself to. Being a guide into that world without, uh, without as many roadblocks as you might find with other, um, forays into functional programming. I had a. A problem with reliability as well. And so I was trying to, uh, find solutions and so I started, yeah, with some JavaScript libraries.

[00:11:05] I was playing around with things like lodash, uh, they had a fp um, plugin or, or subset of functions that, that worked in that way. And I was looking at some other languages and, and some things would be pretty confusing. But then, uh, when I found Elm, it, uh, it really kind of clicked like, oh, okay, these are the.

[00:11:25] The actual things that I'm looking for with it, right? It's, it's not functional programming itself, it's the things that functional programming gives me. So, yeah, I, I understand that.

[00:11:34] Elm stands apart to make developing a frontend fun

[00:11:34] Jared: Um, what is it about Elm that you like that's not available with something with other languages and ecosystems?

[00:11:43] Théophile: Um, I will say having at the same time, um, a language and an architecture, which is the architecture and being able to spin up a server in one common line. So it's the combination of all that, that, uh, uh, that Elm stand is, is really something apart, uh, from the others, uh, in my opinion. And I will say also the, the great work that has done on the documentation, um, and, uh, enforcing all those rules when you create library oil, even in your own codes to document.

[00:12:26] And, um, and yeah, this make, uh, developing a front end fun.

[00:12:33] Jared: Yeah, so you're talking about the documentation that is actually required when publishing a package in the Elm ecosystem, like you must, any publicly available function must be documented, and it must have some, uh, docs. Uh, relationship with the entire page so that it knows where to put it. And yeah, that I think, um, was, yeah, that was a great, uh, uh, thing to have from the beginning, right?

[00:13:04] Because you don't run upon packages that simply have no documentation. Um, it makes you think about that as, as part of the, it's not as part of the process. It's not a thing that you will maybe add later if you've had time. Right. Because those things, they, they don't happen.

[00:13:25] Théophile: yeah. Later is never.

[00:13:27] Jared: Right.

[00:13:29] Why don’t you do it in Elm?

[00:13:29] Jared: Well, speaking of publishing Elm packages, you published, uh, kalutheo or kalutheo elm-ui-explorer. And, um, and do you want to tell us a little bit about the history of how that came about?

[00:13:46] Théophile: Yeah, yeah, sure, sure. Uh, so it, it started because, uh, when I was working at Wika, uh, we, we started using storybook, um, and. I don't know. For which reason we had our own storybook own version. Uh, maybe storybook was not, uh, mature enough. Uh, and uh, we started, uh, using that it saved us a lot of time, uh, on two sides.

[00:14:19] First, uh, when we were interacting with, uh, UX UI designers, we were able to communicate is easier with them and. Not to have to build all the application and to start from scratch and just to isolate, uh, let's say some components in isolation. And on the other hand, it helps a lot developers not to reinvent the wheel and to have more a mindset of reusing, uh, and, uh, having, let's say equation, uh, on the ui. And at that time it was really important because, uh, weaker is a, let's say, client facing application where the, uh, UI in the ER economy is very important. Uh, so we had to be very, very, uh, to pay attention on all the detail. And a storybook is a nice answer for that.

[00:15:23] Jared: Right, right. So you had this experience using it in the re React ecosystem. And then, and then at what point did that, um, did you decide, okay, I'm going to build this for Elm?

[00:15:37] Théophile: Yeah. So, and then, uh, story books started to work well. And then, uh, I was very active in the Elm community, uh, in France, in Paris. We had, uh, Uh, a lot of, um, small events, uh, where we could go and then, uh, share, do some presentation. Uh, and I did a presentation where I kindly hacked storybook, uh, I was running storybook, which is in React, and I, I initiated some Elm, small Elm up as a component which started, uh, being, uh, alive.

[00:16:18] And one person in the audience say, Hey, this is very nice, but why don't you do it in Elm? And I was really beginner at that time and I was like, whoa, it's gonna be hard. And then he said, uh oh, I can even help you, uh, to do it. Cuz there, there are a lot of, uh, help in the, in this whole community during the, the meetups.

[00:16:40] And I think two or three months later I was starting to try to make a storybook with, uh, l Yeah. Like equivalent of storybook. And this is how it started.

[00:16:55] Jared: Oh, that's great. I love that. You know, the, the community is so encouraging to other people. Hey, why don't you, you try this? Who was it in the community, if you don't mind sharing, that encouraged you?

[00:17:07] Théophile: Oh, I don't remember his name. It was, uh, someone in the audience, you know, uh, but I will appreciate it to, to, to see him again. He remembers,

[00:17:19] Jared: Yeah. Yeah. If you're listening out there, why don't you, uh, you know, call, call in, you know, send us a message on, uh, Twitter or, you know, respond? I'll, I'll have my email in the, uh, show notes and, and, uh, Théophile, if you want to, uh, put your contact information in there, uh, we can hopefully find out who that was.

[00:17:40] Théophile: Yeah, for sure. And it really, really motivated me. And, um, like I told you, uh, when you start building, uh, with Elm, even if it's late at home or during some breaks, uh, you know that. You can, it compiles and at some points you have, um, a safe state of your application and you can, uh, iterate very fast. And I start it like that and, and, uh, I manage to, to create something.

[00:18:10] Don't be afraid to start small

[00:18:10] Jared: So when you say you can iterate fast in Elm, what is that process like for you?

[00:18:15] Théophile: I will say not to be afraid to start small. So I will start with a small program without ports. And I will just think about with the modulization, how I want the page to be structured, and then after I can add, uh, port for example, or add more complex, uh, and I do that, uh, progressively, uh, without the fear of breaking everything.

[00:18:46] Uh, and that's what I, I, I appreciate, um, with Elm yeah.

[00:18:53] Jared: Yeah, I think that's a good, uh, good way of explaining it. You know, don't be afraid to start small. I, I, that's a great one. And. For me, I think that I, I noticed folks, and I did this too, when I started, I was trying to avoid compiler errors at all costs. I would, uh, try not to even let them happen. You know, I would be thinking in my head before I saved this file or ran the compiler, you know, what, what do I really need to do?

[00:19:21] And then at some point I learned to embrace that process. Where now instead of. Uh, of trying to avoid those compiler errors. I wanna make them happen. My, I actively seek to make a compiler error happen first. That's usually my first goal. Where can I break the compiler in the most beautiful way? Or not break the compiler?

[00:19:43] But where can I break my program in the most beautiful way so that this, you know, this compiler that is actually my friend, uh, will help me along and guide me. And to the best solution to this problem. And, uh, I found that, you know, if I can find that spot, and there are several of 'em, there's not just one spot.

[00:20:01] But if I, if I go about that in the right way, then um, you know, I can again, start small, start with a, a little break, a little thing that I want to change, you know, whether it be in the view or the model or the update, wherever that part is. Um, or as, as Dillon Kearns might say, um, you know, you, you put in what you wish to happen.

[00:20:21] Théophile: Yeah.

[00:20:22] Jared: you want to be reality, and then, you know, and then a very small slice, and then you do that and then let the compiler guide you around so that you can make that a reality. Um, I found that to be, uh, so nice. You know, I don't feel like I'm out in the ocean, uh, on my own, you know, I'm on dry land and I have, you know, um, plenty of safety around me.

[00:20:43] Théophile: Definitely.

[00:20:44] Jared: Okay, so you. Had this idea to build this right. Based on the, this meetup and these events, you started building it a couple months later. At what point, uh, did you have something that was usable?

[00:21:03] Théophile: I started noticing that when I had folks asking for some merge requests. Uh, I was like, whoa. So it's used. So, yeah. So for, for my personal, let's say, uh, personally I found it very useful because there were no con conent, let's say. And, um, I will say not many folks, uh, was interested on these parts at the beginning.

[00:21:37] Um, and so I started having many people asking from some new features. I added some, uh, responsive, I added some, uh, dark mode. Um, and it started being more and more complex. Uh, unfortunately I had less and less time, uh, but um, At some point, yeah. It's became the, the, the best answer I, I could have to know if it was, uh, usable.

[00:22:06] It was from the community and from the users, and I saw many, um, nice feedbacks about the projects.

[00:22:14] Jared: Yeah, so this was after you had published the package that you started getting these, these pull requests?

[00:22:22] Théophile: Actually I published the package and I also, uh, write some articles about it. And I also shared on Twitter, uh, and I had the chance, uh, to be retweeted. Uh, by famous people in the end community such as, uh, Richard Feldman. Uh, and then it creates some, uh, traction, let's say.

[00:22:49] Jared: All

[00:22:50] Théophile: Uh, so, uh, I, I saw uh many, many messages and, and, uh, I'm happy because today, uh, it's true, it's true that the, the project is not maintained anymore, um, because of lack of, of time. But I've saw many nice initiative, even, uh, some people, uh, building from what I did or going on other direction. Uh, and I think I am happy cause it's created, uh, I think, uh, a nice dynamic.

[00:23:22] Uh, so. I'm very happy for that.

[00:23:26] Jared: Yeah. Yeah. I think it was the first example of a storybook-esque tool in the Elm ecosystem that I was familiar with or that, you know, I discovered. And, um, that for me, kind of opened up that world because I had not seen that kind of a tool before. And what it did for me was motivated me to build, uh, not directly using the tool, but to build a similar UI explorer in our, uh, ecosystem at work Logistically.

[00:23:57] So, um, that was really nice. And that started in 2019, you know, probably after you had already given the talk at Elm Europe. Um, you know, and it had become, uh, made its rounds and, and I had, uh, discovered it and thought, oh wow, that's really neat. I want something like that. And so I introduced that and now I feel like I'm starting to see the fruits of that labor, um, come to fruition because, uh, At, at Logistically for a long time, I was the primary one writing Elm and not a lot of o other folks were.

[00:24:31] And so it was mostly just, you know, for my own benefit and, and you know, kind of hoping a, you know, one of these days other people are gonna really use this. But just in the few past few months we've been hiring more folks and, and they may be, uh, new to Elm or at least, I mean, you know, new to the code base and, and to, uh, You know, to what tools they should use to build things.

[00:24:53] And so I found that to be really helpful. That plus I use, we use elm-doc-preview and so, um, the combination of those, and I kinda link between them, um, both documentation and the UI explorer so that you can kind of, uh, you know, traverse, uh, those different parts and explore. And, um, so thank you for, uh, you know, bringing

[00:25:16] Théophile: Yeah, you, you are welcome. You're welcome. And just to, to add, to add another point, uh, I also started to realize it was, uh, uh, worth it because at my own work, uh, I suggested to use it because we're using Elm and there were no alternative at that time. And, uh, uh, Some people tried and we use it, uh, in, uh, in production for, uh, for many application that we use.

[00:25:42] So it's also a good achievement, I will say.

[00:25:46] Jared: Yeah, that's a testament to it for sure. So you, you use that today? At Veepee, right? Is where you work. I don't know if we talked about that earlier.

[00:25:54] Théophile: Yeah. Yeah. Um, so I work at Veepee, uh, as a lead developer. Um, and uh, when I joined the company there was a lot of folks doing functional programming. Uh, some Haskellers, uh, Some people, uh, using Elm, uh, and I was able to, , to create application around those stack. uh, today it's a bit different.

[00:26:20] The company is changing a bit and, um, either is less, uh, let's say, um, uh, room for, uh, exotic, uh, uh, programming language. I will say. Uh, uh, but uh, still, um, some reliable application have been done with, uh, Elm that I work very well and I was, uh, able to, to, to use elm-ui-explorer for example.

[00:26:45] Jared: Excellent. Excellent. Yeah.

[00:26:48] Getting Elm to production at Veepee

[00:26:48] Jared: So, um, I have a couple questions here. The first one being, what was it like getting Elm to production at Veepee? This, is one of those questions

[00:26:59] that, uh, I've, I've got from Guillaume, Claret, your,

[00:27:04] Théophile: Ah,

[00:27:04] Jared: your friends, so

[00:27:05] Théophile: cool. Uh, uh, hello Guillaume. Uh, first of all, uh, thanks for the question. Um, I think it was, um, like I say, there was a, a good dynamic around that because, uh, many people were, uh, on the functional programming, paradigm, uh, already using it. And even on the, let's say, um, uh, engineering managers or either, let's say people in the company were supporting this, uh, this way of building software.

[00:27:37] So it was easier to, to adopt it. And certain parts is that, um, the department where work we, uh, sorry, we are creating application that are, uh, back office application. So, uh, we don't have constraints of, uh, SEO. Uh, we have more constraints of re reliability. Uh, we want application not to crash. We want application that allow people to be productive.

[00:28:08] Uh, so, uh, by using Elm, uh, we were able to, to build this kind of application and even with, uh, developers that were learning the language. Uh, and this was, uh, I think something that make it work. Um, but, um, for sure, like I was saying at the beginning of the podcast, that, uh, is hard to convince the others.

[00:28:33] So we had to convince. People. And, uh, I was part of an evangelist of Elm when I arrived in the company. Uh, so I was, um, conducting some, uh, workshop, uh, that we were doing during lunchtime. So at the beginning we were only two, and then three, and then four. And then I started seeing people from the business and it was very, very, very, very cool.

[00:29:02] Jared: So with your position at Veepee, do you get to make decisions about what tools you use, at least in your part of, uh, the company?

[00:29:12] Théophile: so as a, as a lead developer, uh, I'm able of course to, uh, to have, um, some final words about, uh, which, uh, which language we can use. But, um, it has to be validated by architects. We have architects, uh, in the company. And also, uh, the risk, let's say, um, he need to be, uh, co um, it's not like anybody can choose his own language.

[00:29:43] Uh, so at at, at that time, it was, uh, the direction that we, we had. In our information system. Uh, today it's a bit different, but, uh, uh, it's not like choosing the languages to play or to work it. It's had some benefits, uh, like I said, uh, having reliable application that don't crash because we're building application for people who are working in the warehouse, for example, uh, who are need to produce.

[00:30:16] Uh, content for sales that we are, we are opening in the websites. So this one was one, uh, let's say, um, reason. Another reason, uh, is that, um, in, um, for example, in my team, uh, we have, uh, full stack developers, which means that, um, they are, they know, let's say the back end, the front end, but they're not specialist on the front end, for example.

[00:30:44] So for this kind of profile, Elm is very interesting because, uh, it, it's, uh, it's reduced risk of, uh, building bad software doesn't mean that we can, we can build bad software, Elm for sure. Uh, but, uh, this rigid or strict, uh, way of doing following the Elm architecture, uh, following some documentation at Adam will make all application look the same.

[00:31:13] Uh, and behave properly.

[00:31:16] Jared: Yeah, that's nice. And I think, uh, for me, when I've brought people on who had less experience with Elm, that sometimes, you know, they may still make mistakes. Like you said, it's. It's not impossible to write, uh, you know, write code that, um, is imperfect, right? I mean, none of it's perfect and it, and your, and more importantly, your requirements can change.

[00:31:41] And so when those requirements change or you find code that is, is not to what you expect it to be, the refactoring process is, is so nice that. Um, I feel like you have more, more freedom in, in how you, uh, bring people in with less experience because, uh, you can fix things, right? And, and, and when things need to change, you can make sure that they change in a way that, um, doesn't break the, the program.

[00:32:13] Théophile: Exactly. Or even for refactoring, uh, we can do a first version that is very, uh, optimistic and then, uh, we can refactor more easily.

[00:32:23] Jared: Yeah. Yeah. That's great.

[00:32:26] Elm as a double-edged sword of reliability

[00:32:26] Jared: And so you mentioned this warehouse management system and, and the need for reliability there. Um, I, I feel like sometimes the, the amount of reliability with Elm. Um, can, can be a double-edged sword simply for the fact that if your requirements aren't changing, you aren't adding new features.

[00:32:49] Sometimes the, the program can sit there working without problems and people forget that, that it was, you know, such an efficient way to do it. They feel like, you know, maybe, um, you know, maybe there's a problem, but the problem is that there isn't a problem. If that makes sense, right? Because you aren't, uh, messing with it all the time.

[00:33:12] You, you, um, you kinda lose, lose it from your, your current, um, site. So, uh, do you have any thoughts about, you know, with your, your system there, um, about how you add Elm things and how that, uh, has affected, uh, Elm as a tool at the company?

[00:33:35] Théophile: Um, yeah, if, if I understood. Well, the question, um, we are, when, um, we start creating, uh, Elm applications, uh, there is this, Sensation that it can break, right? Uh, but then comes the time where we have to add new features or we have to maintain the application. Uh, and um, there are some. Parts that shines on Elm.

[00:34:08] And some parts we are, which are less, let's say, um, let's say, uh, uh, efficient, uh, I will take some example. Uh, for example, we add, uh, in one application to, to create, um, an API. Uh, and we, we add, we're using GraphQL. As a backend for front end. And uh, I remember, uh, at that time we had, um, example, uh, with, uh, React.

[00:34:41] Uh, so we had this, um, stuff called Apollo, uh, and then we had Apollo clients and then Apollo server. And so there was kind of some magic there. And uh, I remember, uh, we had to do the same in Elm and. Of course we started, um, uh, working with some, uh, decoders and then we started creating a lot of boilerplate, uh, which is, let's say one part, I think that end, um, can be painful to work with, with, uh, on that part. But at the same time, it's what make it all clear because you know what you are doing. Uh, so what we ended up with, it was using, um, a library, uh, called elm-graphql, if I remember well, by Dillon Kearns, uh, and. It allows us to just generate, uh, from the specification, all these boilerplates. Uh, so it was uh, let's say an example of uh, where Elm the limit of Amble, but where it can shine also because by generating all this code, cause we had the types on the other hand with GraphQL, uh, Elm played well.

[00:36:10] With, so this is one example of, for like you say, double-edge sword. Uh, okay. Uh, everything is pure, everything is, um, functional, but at the same time, you have to write all your, uh, updates. Decoders function, and no magic.

[00:36:30] Jared: Right, right. Yeah. elm-graphql by Dillon Kearns is, is really powerful and I think that's a good distinction there between, you know, some tools and other languages seem magical, but with Elm it's not magic. You know, there's maybe some code generation going on behind the scenes with some tools, but. It is clear, it's explicit, and uh, and that's, that's really powerful.

[00:36:54] So yeah, we, uh, don't use GraphQL at our work, but we do use, um, some tools to generate code. So we generate Elm from Python. And so, uh, through that process we've been able to gain a lot of power and, and actually make our reliability on the back end more clear by generating Elm, which is more strict and will catch things that we may not.

[00:37:18] Catch on the back end. So, um, I found that to be, uh, pretty nice to have and, uh, of course, uh, make us more efficient. But yeah, the, the real point that I was trying to make with the Elm's reliability is that because it's reliable, assuming that you don't have to add many new features, the reliability, uh, sort of tends to make you forget.

[00:37:44] Or make not, when I say you, I mean make people who are maybe in charge of deciding what tools you use. Um, forget that. Um, Elm was used to build this in that because of its reliability, you don't touch it. And so you don't think about, you know, oh, well, you know, they're working in Elm because you don't have to go in there and fix a bunch of bugs, right?

[00:38:05] So you're not constantly reminded by it. So in that way, I think the reliability, um, makes people just forget how, how important Elm is.

[00:38:15] Théophile: I get, I get the point here. One example is that, um, for, um, some application, uh, for our application, we can use or we are suggested to use, Sentry to be able to catch errors that can, uh, have, we have information on the front end, but uh, for Elm we never had to use, uh, Sentry, for example. So, Once we, if, if we build the application in another, uh, JavaScript, more JavaScript, um, language, uh, framework, we may need, uh, this kind of tool for, this is just an example.

[00:38:59] So, yeah, in fact, we. We kind of forget that it's living. It's there. Uh, and yes, and when you remove it, you can, you will have other problems, but it's a matter of, of trade off. Um, I'm, I'm not saying that, uh, Elm is perfect because, um, sometimes, uh, we, we also ask me, oh, do you think everybody needs to do some Elm?

[00:39:23] He's a member of trade. And, uh, what is your team? Are there junior full stack, uh, you know, uh, specialized and your projects? What are the characteristic types of projects? Uh, do you have to shift very fast? Do you have, you need to have something that is very reliable, like you say so, and then you can choose.

[00:39:45] Jared: Yes. Yes, of course. Yeah.

[00:39:48] How Elm has changed the way Théophile writes software in general

[00:39:48] Jared: And so I guess to that, how has Elm changed how you write software in general? So even outside of writing Elm code, is there some way that it has changed it? This is sort of another adaptation of a Guillaume Claret question.

[00:40:04] Théophile: Yeah, it definitely changed. Um, for my part, I have been, um, I've started, um, programming with, uh, uh, frontend. So with Flash, for example, at that time it was action Script. It was, uh, classes, uh, and uh, abstractions everywhere and we're doing that to create user interface. So we have this burden that extended, uh, a base burden class, and then we have this, uh, let's say, um, interface that we can, um, implement and all this abstraction we are using just to create ui.

[00:40:44] And, uh, what I saw, uh, when I started doing more Elm. And even in React, or or other, um, uh, let's say, uh, front end, uh, frameworks that embraces functional programming. You can describe user interface only with function. And here you say you see that you don't need all those abstraction. You can, you can need some of them, of course.

[00:41:14] Uh, but with functions you can do. Everything and can create very complex application just with function and values, uh, without objects and inheritance and all this stuff.

[00:41:30] Jared: Right. Yeah. And it's, it's funny how I think people tend to naturally move toward complexity. So it take, it takes discipline to keep things simple. But I think, uh, I agree that when you do that, even in, uh, a language that doesn't enforce the same discipline that Elm does, uh, you can gain benefits. So again, for example, with, uh, my work, we write Python on the back end, and I find myself writing a lot of, you know, functions, they're still methods because, you know, I may make a mistake and have some, uh, you know, effect, side effect inside of there. Um, but for the most part, I, I try to write, you know, these static methods that, um, take all of the inputs in and, you know, return values as opposed to accepting glo or using globals or, you know, uh, having side effects and things like that.

[00:42:28] So, um, it's definitely changed how I. Write code as well. Um, so another thing that you've been talking on the French podcast, If This Then Dev about Elm and I don't speak French, so could you tell me a little bit, have we covered some of the things that you talked about on that podcast or are there any things that you talked about on there that, uh, you might be able to share with us in English so we get...

[00:42:58] Théophile: yeah. Um, good question. Actually it's, we covered, uh, mainly, um, uh, the same things. Uh, this podcast was mainly, uh, my experience with Elm, how I enter this, uh, community and uh, uh, what I was doing with it. Um, at work, uh, and, uh, all the, um, functional concepts behind. So I think we're pretty close. I won't say words, words, words, like exactly the same.

[00:43:31] Uh, but if you have any, any question on some parts, I can, I, I can answer, but it was mainly, uh, the same, I will say,

[00:43:42] Jared: Okay. Oui oui. Yeah. Um, that's great. Okay. Well, is there anything else you want to add before we get to the picks?

[00:43:53] Théophile: Um, no, maybe I will, um, like to, to, to, to, to say hi to, uh, my colleagues at Veepee. Uh, I think they really recognize them. Um, and, uh, Alex, uh, Alexza and Jerome from my team and all the others of course, uh, were doing great work in the company, uh, and, um, Yeah. And, and, and Guillaume my, my friend Guillaume who, uh, give this right question,

[00:44:23] Jared: Yeah. Yeah. Thank you Guillaume.

[00:44:25] Théophile: yeah, this is the mainly what wanted to, uh, to say,

[00:44:30] Jared: Okay. Yeah. That's great.

[00:44:33] Picks

[00:44:33] Jared: Well, uh, what picks do you have for us today?

[00:44:37] Théophile: Uh, so the first one, uh, I will say, uh, the Domain Modeling Made Functional, uh, the book, uh, from, uh, Scott Wlaschin. Uh, I really, uh, encourage you to, to read the book. Uh, and I also had the chance to attend the workshop of Scotts. Uh, it's, uh, about domain driven design. Uh, it talks about, uh, functional programming, but also how we can combine both, and it's, it's, it's on, uh, F#, uh, but, um, I, I really encourage, uh, you to go and check this out because it's very, very nice material, uh, to be able to, to work with the stakeholders and the business.

[00:45:25] Jared: Yeah, that's a great pick. I bought that as part of a humble bundle. A couple months ago. And so I have the PDF and I have been reading that on and off. Um, and I think, yeah, it's, it's in F Sharp, but Elm is somewhat influenced by F Sharp. F Sharp is a, an ML uh, family language. And so a lot of the things that I've found in there I think translate really well into Elm as well.

[00:45:54] So yeah. Excellent. Pick. Do you have anything else for us?

[00:45:58] Théophile: Uh, and more on the, on the Elm part, I will say. Um, it's true that we talk a lot about, um, but I, I will, I will want to thank, uh Richard Feldman for his great work on elm-css because it's what I recommend to use. It's kind of, uh, like, uh, css-in-js, but it's elements. And, um, thanks to that, uh, it's one building block of having, uh, UI that is consistent and to be able to put it in the storybook.

[00:46:32] Uh, so I will, I will recommend, recommend it. And also, uh, the material that he produces for Frontend Masters. Uh, all the courses on Elm are very interesting and I, I encourage, uh, people interested by Elm to, to go and have a look.

[00:46:52] Jared: Yeah, those are great picks. The Frontend Masters courses for Elm by Richard Feldman, we give to our, uh, developers when they're starting out. And recently I had watched them. I had not watched those particular ones, but I had seen so much material by Richard before that, um, you know, I thought, well, I, I have the gist, but the fact that it's all so concise and so put together, um, into a single course, uh, makes it great.

[00:47:20] So yeah, I recommend even if you have lots of experience with Elm and you know, you already think you know it all, maybe like I did or assumed that I knew, um, all the material that Richard had more clearly. But, uh, but that really, uh, does put it together well. So thank you. And, uh, any other picks.

[00:47:40] Théophile: Maybe a last one. Uh, as I was saying, uh, elm-ui-explorer, um, is not maintained anymore. Uh, but I, I would like to, to, uh, to say that there is one. Initiative called elm-book, uh, which is, um, seems to be a nice, uh, very nice, um, library to, to make, to showcase and documentation of ui. So I will, uh, I, I recommend it as the elm-ui-explorer author.

[00:48:08] I recommend, uh, this, uh, this tool.

[00:48:12] Jared: Yeah. Yeah, I remember When, uh, is Georges, Georges is that, uh, I'm not sure exactly how to say his name. Georges, uh, Boris, uh, his, um, elm-book project when it came out, I. Thought, Hey, you know, that, that reminds me of elm-ui-explorer. Um, but yeah, it looks really good too, and I know that he's put a lot of work into, uh, into supporting it and I think is, is still continuing to support it today.

[00:48:39] So yeah. That's, that's a great pick.

[00:48:41] Théophile: Yeah,

[00:48:43] Jared: All right. And, okay, so my picks are the first one is, uh, Luca Mugnaini. Again, I'm not sure on the correct pronunciation there, so please let me know if I need to correct that, has a, an Elm 2022 a year-end review, uh, blog post on dev.to, and. That I think is a great post because it showcases a lot of things that were happening in Elm in 2022 and.

[00:49:15] Um, and, and you can really kind of see, uh, all the great things that are going on in the Elm community. And then my last one, which is kind of related to what we've been talking about today, is Elm UI by Matthew Griffith. Um, again, kind of to the point of, uh, of designing, uh, creating a design system, I think that tool really helps with that.

[00:49:37] Um, and so yeah, that's, that's really it. Thanks Théophile for coming to Elm Town and until next time

[00:49:47] Théophile: Thank you Jared. Au revoir . Thank you, Jared.

[00:49:50] ​

© 2024 Jared M. Smith