Ruby Rogues
Navigating Rails for Front-End Developers: A Comprehensive Guide to Integration and Transition - RUBY 654
Wed, 02 Oct 2024
In this episode, Valentino and Ayush dive deep into the evolving landscape of web frameworks, particularly focusing on Ruby on Rails. Join them as they explore the challenges and advantages of transitioning from front-end-centric frameworks like Next.js to Rails, the seamless features Rails offers, and the complexities of integrating front-end components.They also discuss exciting potentials like better integration of Vue component libraries with Rails, the simplicity and utility of custom elements, and the desire for Rails to incorporate features similar to Phoenix LiveView. The panelists share their thoughts on the evolving Rails stack, the need for better tools and documentation, and the excitement around upcoming Rails 8 features.Stay tuned for an insightful conversation about the future of web development, the importance of versatile skills in the development community, and some amazing personal picks from our panelists, including top tech tools, fascinating music, and captivating movies. Don't miss out on this rich discussion filled with expert insights and practical advice for developers navigating the intricate world of web frameworks.SocialsLinkedIn: Ayush NewatiaLinkedIn: Valentino Stoll Become a supporter of this podcast: https://www.spreaker.com/podcast/ruby-rogues--6102073/support.
Well, welcome back to another episode of the Ruby Rogues podcast. I'm one of your co-hosts today, Valentino Stoll, and I'm joined by Ayush. Ayush, do you want to introduce yourself?
Hello, hello. I've been on the podcast for a while, so hopefully frequent listeners would know. But yeah, quick intro. I'm the author of a book called The Rails and Hotwire Codex. I'm on the Bridgestone Core team, and I talk a lot of crap about Ruby.
You just released another version of the book, didn't you?
Yeah, it's a minor update. Just a whole bunch of continuity fixes that a very diligent reader sent me.
That book is so huge. I just imagine a minor update is really like a book in its own capacity.
You can say that again. That's what makes continuity so unbelievably hard.
like some of the mistakes that this reader sent me to like some a piece of code that i'd written that i kind of modify like three chapters later but i'd forgotten to backport the changes and stuff it's like see this is what i'm waiting ai to do right it's just like all this nonsense work that has to happen but like nobody really wants to do it right like
yeah yeah it's really why don't we have a reader bot and it's just like reads your book for you and it's like okay yeah based on this latest stuff you know you should update these things right that would that would be very useful indeed so i we were talking before the show kind of like Rails 8 is on the way here. Everybody's at Rails World and Ayush and I are feeling major FOMO right now.
But we're just watching the stream come through of all of these incredible updates that are just getting pushed out and released and announced today. Some of them we already knew were coming, right? Some of them we didn't. Ayush, do you want to like maybe mention your top highlights so far?
Yeah, so I mean the All I'm looking at is the Twitter feed, really, because we don't have any YouTube streams as yet. Although the keynote apparently will be up later today, which honestly, Ruby on Rails Foundation is bloody amazing turnaround time. Yeah, that's incredible. Have it out on the same day.
But yes, at Rails 8, the highlights are authentication, prop shaft, the solid trifecta, which is solid cache, solid queue, solid cable. thruster and Kamal too. Which the thing that I don't know, maybe I'm in the minority of the thing out of all of that, that I find least interesting is authentication. Because I've always just built my own. I've never been a fan of device or anything like that.
I just built my own. So I don't really care that Rails kind of has it, because I'll still just use the one I made myself.
Yeah, that's fair. You always prefer your own tools in the end.
Yeah, my ego is too big to let me use anything else.
Yeah, I'm with you. I feel like I've seen, you know, we've all kind of like been preparing for this, I guess, solid trifecta that they're calling it now. But yeah, I mean, it definitely makes makes me happy to see, you know, more and more not have to get set up when you first start up a new app. There's nothing worse than configuring something when you just want to get going.
Yeah, yeah, completely. And I think just being able to drop the Redis dependency is something that's quite big. And I'm also, for small indie apps, I think having the three solid libraries along with all the move towards SQLite is just going to reduce the amount of complexity pretty significantly because you don't need a database server anymore either.
And you're just like, yeah, you have one SQLite database for your actual database. You have another one for your cache. You have another one for your queue. And it's just like, just creating files. It's not that hard.
Right. Yeah, I mean, the last leg of this is wrapping everything in WebAssembly so you could just deploy to anywhere.
yeah which i don't know will happen in our uh near term but uh you know what one thing i noticed from the feed i was curious uh what you thought about uh it's kind of what's coming in rails 8.1 which are like the three bigger features that i feel like have been missing from rails a lot which is the action notifier the search and uh house md which i thought was funny is a markdown editor
Yeah, I love that name. Yeah, they announced House MD a while ago and It's something I've kind of been keeping my eye on. But I have a little bit of a scar tissue here with Trix because it's a fairly fiddly editor to use. You can't extend it much. Maybe recently their stance on it has changed, but they didn't seem particularly involved in trying to improve it or even have community involvement.
I created a pull request that literally added an undocumented event to the readme. And I think that pull request remained open up until two or three years later on.
Oh, my gosh.
It was literally just literally two lines with readme. And I know other people who've kind of tried to improve tricks or stuff like that and just not really had much success working with the maintainers.
So yeah, house MD, I'm just tempering my expectations a little bit because yeah, just I think they've obviously built what works for them, which is not always going to work for everyone else's use case. And I'd like the community to be able to improve it and just make it better. But whether that's going to be viable, we'll find out.
You bring up a great point. That's actually one thing I've been a little bit concerned about with Rails in that it's As things grow and get some solid foundation framework-wise, the need for reducing bloat becomes ever greater, especially as the number of maintainers doesn't really increase too much in proportionality, at least. Uh, so I do worry like, right.
Like I've noticed not just with, uh, tricks, but other, you know, pieces of the framework that very similar feedback, right? Like it's very long churn process for changes that really don't affect anything.
Yeah.
Uh, and so I, you know, hopefully, uh, you know, with the rails foundation and everything like that, that is on the radar. Uh, You can make sure that the maintainership at least stays up to date with the progress of the rest of the framework?
Yeah, you'd hope so, but I've read the kind of remit of the Rails Foundation and open source isn't really one of those things. I see a lot on social media about, oh, why can't the Rails Foundation fund this gem or that gem or this maintainer? And I'm like, They never claimed that they would be doing any of that.
If you read the initial announcement, that open source doesn't feature really in their mission or whatever you want to call it. They'll focus on improving documentation, which is something that's happening. Yeah, that's true. Yeah, funding open source is not one of the things they do, and right or wrong, that's not something they've ever claimed to do.
Yeah, I mean, I don't know that they have to throw funding at it. More just like organizational, like, hey, we have this increase in the code base, and we need maintainers. The organizational stuff, I feel like that's where I was hoping that the foundation would add to, right?
so that you know cases like this where you know we we have like only so many limited contributors uh that have like you know approval access to just merge something right uh which is good you know both good and bad but it's like definitely adds a bottleneck um and so i i would like to see something where like i don't know people can vote people in to contributorship right like where
uh, we can create a pipeline that just like makes this process easier. Cause like, to be honest, like somebody going through and just like approving a bunch of the documentation stuff, like that would be huge help, you know? And I know that, I know that's somebody who's probably already like working on that, but like every one of the rails repos, like,
Yeah, so I think that's where there's a little bit of mismanagement, I think, is because the Rails core team is really good, and they have a really defined structure, like core committers and the issues team. And with Rails, they're always on it. Like, I've always got responses to any PRs pretty quickly in Rails.
But then there's some stuff that's in Rails that kind of sits in this gray area, which is kind of in Rails, but not, which is like all the Hotwire libraries are, they're in Rails, but they're kind of not because they're owned by 37signals. Trix is another one because Trix is, action text is in Rails, but Trix is in Basecamp's organization, so it's like 37signals or whatever.
So it's like, yeah, there are certain things that sit in this weird gray area, which is kind of in Rails, but kind of not. And I think that's where all the problems are happening.
Well, you know, I got to hand it to Shopify. They seem to have, like, at least solved that issue with Ruby itself, right? Like, they had their own fork of Ruby for a while, like, handling all of this stuff that they've been upstreaming over the years for, like, copy on write and things like that.
And I feel like, you know, they have had lots of, you know, repos that were basically versions of that that, like, made their way into the official... right? Like realm. Um, so it's possible, right? Like 37 singles is just another company, right? Like, yep.
I don't know. Yeah, it is a bit of frustration with, I know people who've contributed to Hotwire, especially Marco Roth gave a great talk at a few conferences just about obviously all the good stuff in Hotwire, but some of his frustrations as well. And a lot of that was organizational. So... We'll just have to see how this stuff evolves.
And it's just my personal frustration is that some of these things are in Rails as defaults, like tricks and stuff. But they aren't in control of the Rails core team. So that just creates a little bit of mismanagement, I think. But we'll see what happens. Yeah. The other two things that you mentioned for Rails 8.1 are things that I'm very much looking forward to.
Active record search is something that I think is going to really simplify matters.
That is the funniest thing, right? Because the whole Rails...
hype started off of a blog which is like search is like kind of something you add to a blog right as like one of your primary features honestly it's what you had almost any any site that you make with reels uh so yeah i mean it's super i'm super excited about that i hope it's i mean if it's anything like all the other reels uh you know interfaces it should be very straightforward uh are you hoping that it aligns with any particular uh
you know, search gem that you've used in the past?
No, not really. So for my book, I wrote an entire chapter on search, and that's why actually I'm quite happy that it's now built into Rails. And I didn't really use a gem. I just used the full-text search and diagram search features in Postgres and then hand-wrote ARL queries
A lot of this was academic because once you teach a reader how to do those things, then your level of understanding just goes way up. So I'm not really concerned about whether it aligns with a certain gem or not. The main thing is I just hope it has support for full-text search and trigram search because they are different strategies.
Is there full-text search in SQLite? yes there is yeah oh nice yeah i feel like that's something that you know once you realize it's there you're like why do i need other things you know i mean until you start using it heavily but if you just want to like expose a text column like to search on it's like pretty great to be honest yeah like i think again for the vast majority of use cases
just your database search is probably good enough. I can only speak to Postgres because I've not used the full-text search in other databases. But it's actually really good. It's only when you want to start going quite advanced is when you need to reach for something like Elasticsearch.
The client I'm working with at the moment, it's kind of like an AI-powered search engine for people and companies, kind of like a directory of people and companies. And we've used Elasticsearch for that because literally the core offering is a search engine, so we need something quite beefy. But that is probably one of the very few exceptions when I would go
reaching for something like Elasticsearch is when your core offering is literally search.
Yeah, I agree with you there. I mean, I feel like, you know, most Rails apps are like business related, like where you'll have a CRM or like some classic, you know, solution that you're just trying to solve with like your custom data or things like that. And that, you know, having a just quick full-text search or I imagine what active search will become will just be so great.
Just hook it up to a model or whatever it may be, a series of models. I could see it being pretty huge.
Yeah, I think it would really simplify matters. I think it's one of those things that's been a bit of a long time coming, but I'm glad it's on its way now. And the action notifier is another one that is going to be cool because push notifications are just fiddly. It's just the nature of them. It is that they are just fiddly.
And if my understanding of what the framework is is correct, then it's going to handle sending notifications to web, iOS, and Android. So you don't need to worry about any of that on your own. Obviously, the web stuff is what kind of interests me the most because going forward, me personally, my focus is going to be completely on PWAs. I'm leaving the native stuff behind.
Even the second edition of my book is not going to have any native stuff. I'm going to remove it all in favor of PWAs. So web push is something that I need to explore. I know you can do it now in Rails, but Action Notifier would just make it easier.
Yeah, I hope they borrow from Chris Oliver's Notice Gem. I've used that in the past, and it's very straightforward and doable.
Yeah, it is a very easy-to-use interface. I did take a lot of inspiration from it whenever I've built notifications in apps. I've not reached for that library myself necessarily, again, just because I don't really like reaching for dependencies. I prefer building stuff myself because, I don't know, I'm just wired that way. But it is a very solid library, and I look to it for inspiration.
It does add to the list of gems that people will have to migrate away from. Yeah. Yeah, that's kind of frustrating.
True. It's, it's kind of like, just the way rails goes, right, eventually stuff ends up in the platform. And then like, because you had carrier wave and paperclip for a number of years, and then active stories became a thing. And then everyone had to migrate. Yeah, it's just the way it goes. But I think I'm more looking forward to Rails 8.1 than 8, really.
Because, yeah, while I was, I think I honestly should put something in a swear jar every time I mention my book on this podcast. That's a great book, by the way.
I'll wire codecs. Check it out.
Rails are not by Codex.com. Go buy it now. But I had a second edition planned for everything new, and that's going to be a paid upgrade. But looking at everything that's come out, I think I might actually wait for Rails 8.1, because then I can cover Active Record Search and Action Notifier, which are key parts of any web application.
And since I'm kind of standardizing around PWAs, it makes sense to wait for Action Notifier, because I don't want to build my own system, which is, I know, going to be outdated very soon.
Yeah, on the topic of books, I saw Obi Fernandez posting an update to the Rails way, now the Rails 8 way.
Yeah, the Rails 8 way, I saw that.
I'm excited. To be honest, I'll probably learn all the new Rails 8 features by reading that book.
Yeah, I mean, you know that book's going to be solid. It's going to be good. Quite a lot of good stuff coming down the pipeline. What are your feelings on Kamal? Have you used it? Do you have any opinions on it?
I'm interested in Kamal. I'm kind of waiting for it to just mature a little more. All the transitions of traffic, as an example. There's a lot of shifting sands still. I don't personally use it every day. Yeah. Just from what I see, it seems to be like a lot of the infrastructure is changing around as they start to learn more and more the edge cases and configuration options and things like that.
So I do have a couple of like, you know, Doku apps that I would like to migrate eventually. But I'll probably wait till next year, to be honest, just to like let Rails 8 like settle and have everything more firmed up.
Fair enough. That's a good way to go about it. I've kind of just been watching from afar as well with Kamal, largely because it's Docker-based, and I I don't understand Docker well enough to not be afraid of it as yet. So yeah, it's probably just one of those things I need to look at at some point.
But my one frustration with Docker and even Kamal in general is that it adds this additional moving part of a Docker registry. If all I've got is a very simple indie app that runs on one box, I don't want to have to deal with the additional complexity of pushing to a Docker registry and then my server pulling from there. It's just me working on it just by myself, running it on one box.
Why can't I build the Docker container locally and then just push that up to the server?
Yeah. You make a great point, like, why have Docker if you have one server?
Yeah, that's another great point as well.
Yeah, I mean, I feel like it's definitely, like, a foundational choice, right? Like, I think of it as, like, Legos, right? Like, where you have, like, you know, if you just build Legos on a table, like, yeah, that's fine, but you have, like, a sheet where you're, like, sticking the Legos to the build your, you know, thing. It's a lot easier to, to build it as it doesn't move around.
And I don't know, I feel like it's kind of like that as it's like laying the foundation for you to add more stuff that, you know, eventually you're going to need to add it.
Yeah.
You know, I feel like the, the probability of not extending what you have if you actually make something that, you know, you use every day, it's like very low chance that you're not just going to add something new to your stack. And so I like that it's there, right? Like it just, it is like the modular framework for that aspect of things. Yeah.
But at the same time, you know, Docker development is like, it definitely slows you down. Like there are edge cases that you can't even imagine from using platforms, right? Cross-platform use of like a single interface is like, it never works out like smoothly.
Yeah. Yeah, exactly. That's why at some point I want to do just a little deep dive personally into Docker. what it takes to just deploy a Rails app to a Linux box with something like Caddy in front of it and just see if there's a way to kind of simplify that without Docker. Yeah. Because you just don't need Docker
But the one big advantage of something like Kamal, I think, is if you want to sell a Once-style product, like a web app that you just do a one-off sale for. I've been thinking about this for months. Before Once was even a thing, this kind of idea was in my mind. There is absolutely no sane way to distribute a web app without Docker. It's just this rabbit hole of complexity.
It just gets... You're telling a customer to do too much. If I was selling a Rails app that was a one-off sale and without Dockerizing it, I would basically be selling only to other people that knew Rails. No one else would go anywhere near that.
Yeah, that's a good point. I mean... distribution of an application that's bundled up. Like if you're not like creating an executable or something, right. Yeah. Like how do you do that? I do like, we had Andy on about, uh, the glimmer project. Right. And I did like, I like that kind of idea of like literally packaging something up as like a binary.
And like, that's how you, I mean, cause that's a great way to ship things. Right. It's like, okay, those cross platform, like distribution is like already set, established and pretty straightforward. And glimmer is one of those frameworks that, uh, makes that process easy. Right. And like the whole, like, uh, you know, Dragon Ruby toolkit for game distribution.
I feel like all that's really missing. And I know that like Andy was mentioning that he's trying to work on that, you know, front end aspect of the Glimmer project. But yeah, that's what's missing is kind of like the web side of that distribution where we have like the browsers now, which I think the... you know, I thought the goal of the browser was to be that distribution platform.
But it's like the competition between the browsers has just like stifled progress, like so much, like it's kind of remarkable. People are just like, okay with that. Like, yeah, we're just going to like, you know, no, no problem. Like all these browsers are competing. So like, we're just not going to have a distribution platform for, you know, web.
That's crazy to me. It is a bit weird. Yeah, I don't know.
I was hopeful with Travel Ruby or something like that that we'd see maybe something a little more progress, but I guess it's hard to sell that, right? If your end users are all distributed, how do you deliver the best thing, right?
Yep, it's no simple problem. If it was simple, it would have probably been solved by now.
That does bring me to another announcement with the Turbo, what is it?
Hotwire Native.
Hotwire Native? Yeah. Yeah, because we did, we had, I'm blanking on his name now.
Joe.
Yeah, Joe, we had Joe on before a few times, I think. Oh, okay. He was talking about Turbo Native and the progress that he was making there and apparently has been collaborating, right, with 37signals. Yeah. Which is really exciting because I know the last time I was messing around with that, it's, like, pretty decent.
I mean, they're still, like, still got to write some Objective-C or not Objective-C, but, like, Swift and Android. Like, a small amount of code now.
Yeah, but I think it's the right approach that you still have. You have an Xcode project, an Android Studio project, your code base is still separate. I think that's a very good approach. And I spoke at length about this at a couple of conferences last year. So if you look up building Turbo Native apps with my name, you'll find my talk at friendly.rb last year.
about this and I completely agree it's the right approach and honestly what they've done just seems more like a rebrand and I think it is a rebrand for the better because having Turbo Native and Strada as separate things it was just a little bit confusing and they've just unified those under this Hotwire Native umbrella now so it's one thing like both the native kind of worlds are just one thing
And the documentation is a lot better, which I believe Joe helped out with. And the other thing was, I think Joe also built a library called Turbo Navigator, which is a lot of the native navigation stuff on iOS you have to build on your own. But on Android, it's kind of part of the platform. So Joe had built this library called Turbo Navigator
which kind of brought the same ergonomics to iOS as well, which now I believe is part of Hotwire Native. That does simplify life on iOS as well. So yeah, it's all just very good stuff. Stuff I'll personally remain quite blissfully ignorant of, though, because I've had enough of Native in my life. I don't want any more.
yeah and it it's it's gonna be hard to stay away from it with all this apple intelligence stuff uh now even increasing the hype uh and i imagine you know there's a google version of that out there too uh you know drawing more and more people to their mobile devices yeah quite possibly yeah but i don't know i think
PWAs, I hope, it just needs better marketing, I think. And it also needs the big tech companies to kind of come on board with it, which is the harder part. What I would really like to see is the ability to put a button on a website that says install to home screen and you tap it and it just does it.
Because like now, the best solution you can have is you can have that button and you can have instructions on what to do, which is usually like click a share button and then add to home screen or whatever. You can't automate that. There is no API to do that. But you can see why Apple and Android don't want to do that.
Why?
We don't have to get into it.
Yeah.
Yeah, something to do with green paper.
I will say, like, just taking a step back to the conference again, Rails world. I mean, it is packed. You see the audience in a lot of these photos. And it's kind of exciting to see, you know, people all over the world coming together, making this stuff happen and shipping stuff. It's, you know... There's no way Rails can be dead with that crowd.
Oh, yeah. Rails is just not the fashionable thing anymore. I've been asked before. I've only come to Rails in 2020. I was a mobile developer before that. I've been asked, did I find Rails to be some kind of niche framework? or something that was in the past when I got into it. And I'm like, no, I never thought that for one second.
I always thought of it as a mature, solid piece of technology that just wasn't fashionable anymore. And I'm fairly cynical enough to not give a shit about the fashion aspect of tech. Like, I mean, you have Angular, you have React, these things just go and come in waves and I'm like, just let me write HTML and CSS like, and, and Ruby on the backend. That's the generates HTML and CSS.
And I'm happy about anything else.
Yeah. I mean, it's hard to, you know, it's hard to sell somebody focused on front end, like a framework that they don't understand, uh, And it's, you know, likewise the same way, right? Like I know a lot of front-end people that are like, you know, very happy with, you know, Next.js or something like that. And they're very efficient in it and it makes them productive.
Like, you know, why would they switch to Rails? And maybe until they need like file upload or something. Yeah. No, I don't know. There are some things in Rails that do just work, and they make things very easy. And so I feel like the more we can expose what those things are and how easy it is, the more people will adapt to it, for sure.
Yeah, completely. Yeah, there's nothing to add to that.
So what's something I'm curious, because you're kind of all over the place in the stack. What's something from Rails that you use that you've used in other frameworks that is just unparalleled to using Rails with?
I don't know. It's hard to pick just one, because Rails is the only backend stack that I've ever used. So it's hard to compare it to something else. But everything you need to build a modern web app is standardized in some way or the other. When you look at other stacks, this is more anecdotal from when I go speaking to JavaScript people. It's that you kind of need to pull in stuff
plugins and things for basic things like file upload, you need to go look for a plugin for that. Authentication, you got to go look for a plugin for that. You basically need to build a stack that Rails gives you already out of the box. If you're building a web application, all the pieces you need are already in Rails. which obviously makes it a bit of a behemoth.
And when you need something very simple, it's not the right tool for the job for that reason. But for most modern web applications, you do need all that and Rails just gives it to you.
Yeah, I agree there. I mean, it's a little tricky because like I'm still trying to find the right like, front end magic, right? Like if I want to like, I don't know, add some like UX flourishes using some, you know, MPM package or something, uh, there's like kind of eight different ways to integrate that into the real stuff.
Uh, and so, I mean, I, I know that like, you know, there, there is some hope in the, in the pipeline coming. Um, but it's still very much divided on how the best approach is, like the standard is kind of still not firmed yet. I don't know, what's your impression there on like, you know, integrating front-end components that are external to the ecosystem?
It's, yeah, but I kind of want like, so I quite like Vue component, the library. uh i know there was some chatter to merge that with rails um the last time i met joel hawksley who's the leader of the project uh which was 2022 summer 22 at brighton ruby he still had ambitions of of merging it into rails so That is one dependent.
I don't reach for a lot of dependencies naturally for every app, but ViewComponent is one of them. And I quite like that approach because it, again, focuses on generating HTML on the server, which is just the construct with which you generate it is componentized. and you send that down to the browser. And then if you need JavaScript components, I just use custom elements.
They are absolutely amazing. It blows my mind that they're not more widely used than they are. They are just so, so useful. Last year when I was helping out with the Rails World Conference website as mentoring the junior developer who built it, And we needed to put a back-to-top button on the web page, which appears only when you've scrolled down twice the height of the viewport.
And this was a Jekyll app, so we didn't have a JavaScript pipeline. And I don't hate myself, which is why I didn't want to set one up. So we were limited to basically vanilla JavaScript. So my first instinct would have been to reach for a stimulus controller.
But I didn't really want to pull in JavaScript dependencies because we were just writing vanilla JavaScript without any kind of bundling or anything. So I just showed her how to use a custom element and it was just so elegant and so simple. And it's just such a great solution to so many problems.
Yeah. It's funny. You mentioned Joel Draper.
Joel Hawksley, Joel Draper is Joel Draper is the flex guy, right?
Flex guy. It made me think of the flex guy.
Okay.
Yeah. The view component stuff that Joel Hawksley is working on is, is really impressive. I mean, there's only, there's always so much like coming out there too. And I, and I, It makes me think of Joel Draper, who is funny. They're both Joel working on similar things.
Yeah.
With the Flex repo. I mean, I just saw... I've been following the... F L E C K S. Uh, which basically makes like a, uh, bi-directional, you know, data coupled view component basically with flex, uh, that you can like serve asynchronously over web sockets. So like get updates, really cool stuff, uh, where you get kind of like the data coupled, uh, backend to the front end in a single component.
It's like really neat. Uh, To be honest, the whole Phoenix live view, which has been out a long time, right? Yeah. I've been waiting for something like that in Reels for the longest time because we're close with Hotwire. I know that was kind of supposed to be
uh the driver for that it is still a little bit clunky i think with all the ids and trying to manage what streams to what and what what file holds what update right and what gets executed where it's still a little bit hard to follow uh yeah it is i've not used live view but uh live view is obviously purpose built for one thing and stuff like action cable and and uh the
the broadcast system within hotwire is uh just like a feature of a bigger thing so yeah i guess that's why it just it feels a bit bolted on because because it is it is yeah that's funny but you know i mean i'm hopeful like it
It's a, it's funny that like, you know, Vue component as an example, hasn't like kind of made its way into the Rails ecosystem with how, with its longevity, right?
Yeah.
Obviously there's some trepidation for a reason, right? Like it, it does introduce kind of some, you know, DSL that you have to be familiar with and it's not quite as realcy as it, It could be. I guess it's more the Ruby way than the Rails way, which is kind of funny.
Yeah, that's very true. I don't know exactly what the objections to getting it into Rails were, but yeah, that is probably likely one of them is that it just feels a bit different. I couldn't articulate exactly why. Yeah.
Yeah, it's funny because I remember, you know, I haven't done view components in a while, but the last I did, it was like great encapsulation. You know, you could test the changes that get made to your component. It's encapsulated perfectly. And you know, when you mutate the props, the actual HTML gets rendered, gets changed in specific ways and you don't have to worry about it. It's all Ruby.
I mean, there's a lot of appealing qualities of it. Um, But yeah, I feel like it becomes the same like front end issue of, okay, well, how do you extend it? How do you like add these custom components or custom features? And then you end up tied into the DSL of the framework and because it's its own framework. And I feel like Flex kind of has the same issues there too, right?
If you wanted to create your own, you know, element or something like that or component. It's not exactly straightforward because you have to follow however the framework has it set up. And all of these things go against what most front-end people do. So I feel like the Rails and Ruby developer ecosystem that's full stack slowly gets narrowed in as you get to the front-end.
It's been back-end heavy for a long time. It's been shared. It's getting wider, right? But I feel like even still that... your audience narrows quite a bit when you get closer to the front end side of things.
Yeah, it does. I don't know. Maybe I'm a bit old school. I don't really see a massive reason for there to be this demarcation between front end and back end. Sure, you might be better at one compared to the other. But I think if you're a web developer, you should just be able to do everything.
Well, I think it comes in, I'm torn, right? Like I've been at a small organization where having full stack people is, you know, very beneficial. And like when you have fewer people, it's just easier to move faster if everybody kind of touches on all the same things.
But in a bigger organization, too, it's like kind of nice having people that just devote themselves to like making sure front end components work smoothly. Right. Or like once you get a design system in play, making sure that all the components are uniform across all of your applications and making sure that like things is like it's a smooth experience for the user.
You know, UX is like on its own is amazing. probably its own, you know, field. And so like, if you have a team devoted to just UX, like the number of backend things they'd have to work on is going to get smaller and smaller as they start to, you know, work on more and more of that system that they're building, to be honest. And so it's like, it's a double-edged sword really.
Cause like maybe for like, maybe for most people working in Rails, right? Like you want that full feature set and full stack mentality. Yeah, as a larger entity, it just like becomes less and less attractive or desire, like your need for it starts to thin out, right? After a certain point. So I don't know. The problem is like we need both.
yep I don't know the desire for specialists is like kind of still important right like yeah yeah it is you're still gonna need somebody to work specifically on security at some point if you if that's part of your core business right and or if you have regulatory aspects of your business you know you're gonna have these specialists that are in demand no matter what so I don't know the
It's hard because as a perfect example of security, active record encryption is awesome. When they were first releasing that, they had a third party auditor come in and make sure that all of the encryption stuff, because nobody's working on encryption stuff specifically on the Rails core team. I mean, there are a handful of people that have knowledge of it, right? Yeah.
But they're not, like, working on the new algorithms, you know?
Yeah. Yeah. Yeah, that's probably murky territory. I'd be worried if they were working on the algorithms.
Right. Yeah, like, what are they sneaking in, right? Yeah. Yeah, it just reminds me of that. And because Adam Gordon Bell, he has this great podcast, The Co Recursive Podcast, and he had somebody on. They did this whole like dialog, like reenacting that security incident recently.
that made it into the compiler kernels, um, from some like, you know, Chinese co-conspirator supposedly like, you know, they don't really know like too much of the details, but just like, you know, part of the, I forget, was it the GNU compiler? It was some, something tangentially related to the assembly aspects of compiling, uh, where they were able to get like, uh, you know, a, uh,
I don't know, some kind of permutation to the compiling that made it inject code with anything that was compiled with it. And that spread like crazy. It was just a very interesting dialogue. but eventually think of this stuff, right? Like, you know, what else is just like in there?
There's no, I mean, you'd be selective of your contributors, but I don't know that that's a, like a long winded thing about, you know, specialists really, but like, you know, I don't think we should shy away from them. And you know, the more we can keep things modular and accessible, the better that the framework will be. But,
Yeah, I completely agree with all your points on specialists. And it's absolutely a good thing when you have someone who's gone really deep on one aspect of maybe front-end or back-end or whatever. But I also think that you shouldn't be completely unaware of the other thing. If you're a front-end specialist and you're ace at that,
It shouldn't mean that you're afraid to create a model, a controller, a database migration, that kind of stuff. Yeah, sure, you may not be as good at it as someone who specializes in the backend, but I think you should be competent enough to be able to do the basics.
Yeah, I don't disagree with that. I think having the tools and the framework that makes that easier to do the better, like all these generators are great. I mean, to be honest, I would like to see some improvements there to the whole generator aspect of things and customization, uh, which I know you already can do, but, uh, I don't know.
It seems like, uh, not straightforward as a first time user on like what you can generate, what's available, like the, you know, that is definitely discoverability is definitely still a problem yeah which the the guides are great i'm so happy to see all the documentation you know getting the tender loving care that it needs
But, you know, it's still like discoverability problem is, you know, even on the development side is still an issue. I don't know. What do you what do you point people to that? Like, let's say you're talking with somebody on the JavaScript side and you're like trying to convince them, you know, hey, like, it's not so hard. Like, what do you point them at?
Yeah, it's a good question. Off the top of my head, I wouldn't know what to point them at. I'd probably look for a blog post, to be honest. I'd probably look for a step-by-step tutorial on how to create a model or whatever.
because the Rails guides are very good, but they're also kind of aimed at someone who's actually trying to learn Rails or is familiar with Rails, which is fine because you need to write for a certain target audience. Otherwise, nothing's ever going to make any sense. But yeah, if I'm talking to someone who's more front-end, he doesn't really know much about Rails.
And unless they're keen to really get into Rails, the guides is probably not where I would send them.
That makes, somebody should go create a Ruby toolbox for Rails tutorials, right? I feel like there's value, so much value there.
I should just buy my book.
Or buy Ayush's book. Go ahead.
In case you don't know, Ayush's book, the Hotwire Codex. Rails and Hotwire Codex.com, go and buy it now.
Honestly, that book is so impressively, like, large and, like, covers all the topics you could possibly need. Like, we should be pumping it out there because, like, honestly, hey, if you have questions about that Hotwire framework, like, it's in there. The answer is in there.
Yeah, and if it's not, you can email me.
Right.
And you can demand, like, I demand that you write about this feature. Yeah. I may not pay any attention to your demand, but you can write me if you want.
Oh, that's great.
So what else do you feel like you're missing out on in Rails world?
I don't know. For me, I think conferences are just about networking. I don't necessarily miss any of the talks because I just catch up on YouTube afterwards most conferences these days. Put the talks on YouTube. The main reason I kind of wish I was there is the networking aspect, especially as a freelancer. It's kind of key.
But again, as a freelancer, getting over to Toronto and paying for, I think it was like $500, $600 ticket on top of hotels and flights. It's just like... And then the opportunity cost of lost income, because if I go, it'll be probably a week, and that's one week of income lost. You're looking at, when you combine everything, you're probably looking at closer to like $5,000.
And it's like, do I really want to spend that much? I'm going to New Zealand for six weeks at the end of the year, and I'm probably spending about 6,000 pounds for that entire trip for six weeks. Yeah.
Yeah, you know, you're in the European region too, which has so many great conferences. Yeah, I understand totally. I actually have FOMO myself about all those great conferences that are there that I just probably won't ever get to.
Yeah, they're really good. I think I'd give a shout out to Friendly.rb where I spoke last year. It was last week. I couldn't go this year just because the dates didn't work for me. I had another trip planned. But if anyone's looking to get over to Europe, that's probably one. And I'm speaking at Haggis Ruby next month as well. That's the first year of that conference in Edinburgh.
So that should be fun because Ollie, who we had on this show, I think two or three weeks ago, he's a speaker as well. So I'm sure that'll be a good conference as well.
Yeah, Edinburgh is beautiful too.
Yeah, lovely city. I love going there.
Well, we've talked about so much here.
Yeah, I think we've covered everything that we know of at this point.
We're going to have to have some follow-up talks with some of the co-creators here.
Yeah, I think we really need to get Rosa on to talk about Solid Q. I love that. Yeah, and I think we should get someone. I think it's Donald... who handles a lot of the Kamal stuff. I'd love to get him on and chat Kamal with him. Yeah, we'll have to schedule it.
Yeah, got a couple of names. So many great insights there, you know, what's coming out. You know, it's hard to use it all, you know, right away. So it'd be good to expose kind of how it all works and how you can benefit from it because I want to know.
Yeah, exactly. Sometimes the best way is just to have a couple of idiots like us just ask stupid questions to the expert. And that's how other people can also learn. So definitely worth getting them on.
All right, well, is there anything else you wanted to talk about today, Ish?
No, I think that covers it.
Awesome. Well, let's move into our picks. All right.
Do you want to go first or do you want me to? Yeah, I'll go first. So I'll do a musical pick and a movie pick, I think. I don't have... Actually, I'll do a tech pick as well. So I have a musical pick. I went to see a band called Big Big Train on Tuesday. They're like an English progressive rock band. To me, they kind of... just embody England as a country.
They're like the most English band you could ever have. They sing about like the history and the countryside. And they had one album, which was like about a little bit about space exploration. They have a song called Apollo and Voyager and stuff. They're like very, the latest album has two songs about cricket. So they're about as English a band as you could possibly get. So I absolutely love them.
They're a great live band as well. I believe they're over in America next year for a few shows in the spring. So if live music is your thing, I'd recommend checking them out. I recently saw a movie called See How They Run, which I just loved it. It's a twist on the whodunit genre.
So it's kind of... The events take place around a performance of the play The Mousetrap, which itself is a good old-fashioned hoot on it written by Agatha Christie, which has been running here in London for something like 70 or 80 years or something silly like that. So the events of this movie take place around that performance and it is just...
such a self-aware and self-deprecating movie like how deadpool is self-aware for superhero movies and kind of makes fun of itself i think see how they run is equally self-aware to the hood on a genre and equally makes fun of itself and i just love movies that are like that it's like we know we're full of shit and we're not gonna make any pretense that we're not full of shit
It's brilliantly written. So yeah, that's my movie pick. And yesterday, I was just looking for some applications that would help me screen record and webcam record at the same time to do a screencast or something if I just want to send a demo.
of something i'm doing to a friend i couldn't find something that was like cheap just that literally just did this one thing which is record my screen and the webcam and give me a video file at the end But then I found this app called CleanShot X or CleanShot 10. I don't know which one. But yeah, cleanshot.com. I haven't bought it yet, but it looks exactly like what I'm after.
So if you're looking to record screencasts, CleanShot is probably a good way to go if you're on a Mac. Right, that's my picks.
Awesome. Yeah, I'm going to have to check these out. So I have just a couple of picks here. The Ruby AI happy hour is happening in New York City. This time they're doing a demo night. So I'm excited to go to that. Actually giving a demo of a project I started called Podcast Buddy, which I hope to have on the show soon.
But a little AI companion that can join and answer questions, describes the whole thing and summarizes events and things. So I'm pretty excited about demoing that. And I was hoping to get a fully offline version of it working. But the, you know, the talkback aspect of it is like very much just like a speak command at this point to OSX or Mac. Yeah.
Otherwise, there's, like, servers involved and, you know, way too many dependencies to get the text-to-speech working just right.
Simple is good. I like simple.
Yep. So check it out, Podcast Buddy. You can run it. just in the command line, and it'll transcribe your conversation. I use it for meetings, too. It's great. Fully offline transcription using Whisper CPP. And next to that, I was revisiting something, one of our projects at Doximity called Simple Kick. It's a job orchestration for Sidekick. And it's fantastic.
It gives you like ways to run jobs in parallel and orchestrate many things at once and get callbacks when things are complete or if there's failures. It's super useful. And I would definitely recommend checking that out as well.
What's it called again?
Simple Kick. So simple and then K-I-Q.
Okay. Nice. Cool.
And we build it right on top of Sidekick itself. And it does require Sidekick Pro, but
Okay. Yeah, I'm just looking at the readme now because I was going to say that my client, we pay for Sidekick Enterprise and we've got quite a lot of complex stuff around batching and callbacks and stuff like that. So I'll check this out. Maybe it can make life easier in some way or the other.
Oh, yeah. I mean, I have a few things working with this and it just it does. It makes the whole process just like so streamlined. Nice. Easy to reason about. Well, that's it for me. I hope everybody out there is enjoying Rails world feed as much as we are. And hopefully we can get some of these, you know, some of these speakers lined up here and dig in some more on the details coming soon.
Yeah, absolutely. It'd be great to get them on the show and pick their brains.
Yep. Until next time, folks. Valentino out.
Cheers. Take care, everyone.