Menu
Sign In Search Podcasts Charts People & Topics Add Podcast API Pricing

Andy Maleh

👤 Person
308 total appearances

Appearances Over Time

Podcast Appearances

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

You can just use variables the normal Ruby way and variables will identify elements. You can grab elements by variable instead of by ID. uh, in general, like in general, you don't have to refer to IDs and elements. Uh, so it's even, it's simpler than jQuery. It's simpler than my mind a bit than the mental model of turbo. Um,

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

You can just use variables the normal Ruby way and variables will identify elements. You can grab elements by variable instead of by ID. uh, in general, like in general, you don't have to refer to IDs and elements. Uh, so it's even, it's simpler than jQuery. It's simpler than my mind a bit than the mental model of turbo. Um,

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

And it can do things that are fully like just front-end only interactions that don't even talk to the back-end. So as far as I know, Turbo is usually augmented by stimulus. I find stimulus as code a bit boilerplate-ish because it requires people to write controllers. I find that a bit too verbose, personally. I feel like it's not dry enough. It could be drier.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

And it can do things that are fully like just front-end only interactions that don't even talk to the back-end. So as far as I know, Turbo is usually augmented by stimulus. I find stimulus as code a bit boilerplate-ish because it requires people to write controllers. I find that a bit too verbose, personally. I feel like it's not dry enough. It could be drier.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

But also it's written in JavaScript, which is very ugly compared to back-end Ruby code. Like, even if I'm writing a tiny bit of sprinkles in JavaScript, if I can write them in Ruby, it would be even better.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

But also it's written in JavaScript, which is very ugly compared to back-end Ruby code. Like, even if I'm writing a tiny bit of sprinkles in JavaScript, if I can write them in Ruby, it would be even better.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

Yeah, one of the issues with previous attempts of providing a front-end development library that would use Ruby, like Opal Ruby, for example. For example, there was a much older framework called Vault that was a bit popular around 2015 or 2016. Vault was basically providing people with a full isomorphic approach to development on the web so that you write the front end with Vault using the Ruby.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

Yeah, one of the issues with previous attempts of providing a front-end development library that would use Ruby, like Opal Ruby, for example. For example, there was a much older framework called Vault that was a bit popular around 2015 or 2016. Vault was basically providing people with a full isomorphic approach to development on the web so that you write the front end with Vault using the Ruby.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

They might have had a DSL. And then on the back end, they basically have models that can establish connections to the back end directly without you writing controllers or writing REST APIs on the back end, if I remember right. It was a very innovative approach. It had very good ideas. The issue with it was that it forced people to change their mental model for Rails too much. That's a problem.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

They might have had a DSL. And then on the back end, they basically have models that can establish connections to the back end directly without you writing controllers or writing REST APIs on the back end, if I remember right. It was a very innovative approach. It had very good ideas. The issue with it was that it forced people to change their mental model for Rails too much. That's a problem.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

If somebody wrote a Rails app that is doing very good for their business and it's been around for five years, it might be too much to ask for them to change their entire apps approach right away to something like Vault. So Glimmer is aiming to intentionally provide the simplest possible thing that you could use to augment your Rails app with something better on the front end and no more than that.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

If somebody wrote a Rails app that is doing very good for their business and it's been around for five years, it might be too much to ask for them to change their entire apps approach right away to something like Vault. So Glimmer is aiming to intentionally provide the simplest possible thing that you could use to augment your Rails app with something better on the front end and no more than that.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

So I intentionally just provide a drop-in replacement for your JavaScript library on the front end And the nice thing about it is JavaScript frontend apps are every page is its own app. So if you have older things built with jQuery or React in the past, it doesn't matter. You can start any new pages using Glimmer and it's very easy to add it and you can get started very quickly.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

So I intentionally just provide a drop-in replacement for your JavaScript library on the front end And the nice thing about it is JavaScript frontend apps are every page is its own app. So if you have older things built with jQuery or React in the past, it doesn't matter. You can start any new pages using Glimmer and it's very easy to add it and you can get started very quickly.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

My plan behind that is it would expand gradually in the future so that more and more pieces can be added if people want to optionally. So the second, so you mentioned that now things are coming together in a way, because finally, like on the backend, we have things like flex or view component. And on the front end, there's, you know, Glimmer DSL for web.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

My plan behind that is it would expand gradually in the future so that more and more pieces can be added if people want to optionally. So the second, so you mentioned that now things are coming together in a way, because finally, like on the backend, we have things like flex or view component. And on the front end, there's, you know, Glimmer DSL for web.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

My idea is to actually extend Glimmer support to the backend as well. So eventually you write your Glimmer web components on the front end. And then I want to support server-side rendering of them on the back end. So that way on the back end, you don't have to use ERP anymore. You drop ERP and replace it with a much simpler Glimmer DSL.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

My idea is to actually extend Glimmer support to the backend as well. So eventually you write your Glimmer web components on the front end. And then I want to support server-side rendering of them on the back end. So that way on the back end, you don't have to use ERP anymore. You drop ERP and replace it with a much simpler Glimmer DSL.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

But basically, it would work kind of like Vue Component or Flex. Like the back end controller actions will just render Glimmer components. And if you render them from the back end on first hit of the website, they will... first render the HTML and then they will hydrate and add the JavaScript layer on top of that. There will be a bit of work to explore that idea, but that idea is on the horizon.

Ruby Rogues
Building Better Ruby Apps: Glimmer's Component Slots and More - RUBY 653

But basically, it would work kind of like Vue Component or Flex. Like the back end controller actions will just render Glimmer components. And if you render them from the back end on first hit of the website, they will... first render the HTML and then they will hydrate and add the JavaScript layer on top of that. There will be a bit of work to explore that idea, but that idea is on the horizon.