Teaching Ruby? Trying New Gems? Use Bridgetown!
Happy May everyone!
As a core member of the Bridgetown project, I realize I’m biased. I think every Rubyist who works on or even near the web should take a look—especially anyone who has current or past experience using Jekyll. But today’s post on RUBY3.dev isn’t about Bridgetown per se but about how the next big release, v0.21 “Broughton Beach” (currently in beta and due out in late May), provides an intriguing new environment for teaching and learning Ruby and trying out new tools in the Ruby ecosystem.
One of the new features in Broughton Beach which is germane to this discussion is the ability to write web pages in pure Ruby. You can now add a page, or a layout, or a data file, using nothing more than .rb
. Basically you can write any code you want, and the value returned at the end of the file becomes the content of the page. So you can build up web page markup using string concatenation, fancy DSLs, transformations of incoming data, the whole nine yards. And you can add methods and inner classes and anything else you need to accomplish your objective.
I hope you enjoy this special preview of Bridgetown 0.21! Please reply to this email if you have any questions or ideas.
Cheers,
Jared