Advertisement Β· 728 Γ— 90

Posts by David

Post image

Just wrote up how I set up SQLite backups for a Rails app using Litestream and Cloudflare R2
Litestream streams your database changes to S3-compatible storage in near real-time, and the litestream-ruby gem handles the Puma integration nicely

dcyoung.dev/shorts/setti...

#rubyonrails #webdevelopment

3 months ago 4 0 0 0
Preview
Reading Roundup: Prototyping, Rails Views, Custom Elements, and Elegant APIs Here’s a short roundup of articles I read this week. Quick takeaways below so you can scan fast and dive deeper where it helps.

Reading Roundup is live.

Prototyping in code, Rails view performance, custom elements, vanilla CSS, and building elegant Ruby API clients.

Quick reads worth your time. Full issue here: dcyoungdev.substack.com/p/reading-ro...

#RubyOnRails #WebDevelopment #SoftwareDesign

3 months ago 2 0 0 0

I've been trying out Claude (desktop app) with an Obsidian MCP plugin - using all these words sounds more technical than it was πŸ™ˆ
It's been pretty good so far, it pulled together pretty decent weekly summarise based off daily entries.
I followed this without the optional steps dev.to/sroy8091/con...

3 months ago 1 0 1 0
Post image

API token code got you spooked? All that SHA256 hashing and secret key management scattered everywhere?

I found a cleaner way using `has_secure_password`, `authenticate_by` and `authenticate_or_request_with_http_token` in Rails.

Full writeup: dcyoung.dev/shorts/api-t...

3 months ago 1 0 0 0

dcyoung.dev/feed.xml

10 months ago 1 0 0 0
πŸŽ“ How .excluding works in Rails Rails provides a convenient .excluding method for identifying a group of items while omitting another set.

You might get less performance from using `.excluding` than `.where.not` and here's why.

dcyoung.dev/shorts/how-e...

#RubyOnRails #WebDevelopment

10 months ago 8 1 0 0

Yeah it's really nice. Will see how the print holds up after a few washes but didn't crack when gently stretched πŸ‘Œ
Looking forward to more designs 🀩

1 year ago 1 0 0 0
Me wearing a Ruby t-shirt

Me wearing a Ruby t-shirt

Upped my geek level thanks to @andycroll.bsky.social and rubytshirts.com πŸŽ‰πŸŽ‰

1 year ago 9 1 1 0

Example: You add a new column to your database and you want to fill it with some computed value. You calculate a score for each post based on interactions. You have a service `PostScorer.score_post(post)` that returns a number that you want to store in your new `posts.score` column.

1 year ago 0 0 0 0

What's your preference when it comes to data migrations in a Rails app?
I've used the data_migrate gem in the past with mixed success - I think it stopped working for me after an upgrade (gem or Rails)

Let's discuss the pros and cons.

#RubyOnRails

github.com/ilyakatz/dat...

1 year ago 0 0 1 0
Advertisement

I feel your pain, an asdf upgrade tried to take me down today!

1 year ago 2 0 0 0

I've had some good success with CUBE methodology.
piccalil.li/blog/cube-css/

1 year ago 0 0 0 0
πŸŽ“ New Rails application with asdf I use asdf to manage my runtime versions (Ruby and Node). This makes life a lot easier when switching between multiple codebases and allows me to easily to switch machines due to the presence of a .to...

Haven't quite got to what I update in Kamal but this is my WIP dcyoung.dev/shorts/new-r...

1 year ago 1 0 0 0
Preview
The Curse of Service Objects Service Objects were a mistake. It has nothing to do with OOP. It has little to do with ideas of Fowler, Evans and Martin. I analyzed a plenty of open repositories, videos and articles, and in this ta...

Enjoyed this talk about the Shape of Service Objects. I like the separation of work explained and the visual representation of a Service Object is great 😍 - off to find some code to analyse + refactor 🧐
www.rubyvideo.dev/talks/the-cu...
#RubyOnRails

1 year ago 0 0 0 0
Preview
How to use params.expect in Rails 8+ (Example) - GoRails Rails 8 introduces a new expect method for permitting parameters that fixes a few of the issues with require and permit. Let's take a look!

Rubocop gem update adds a check to ensure Strong Params expect is being used.
@gorails.com have a great video explaining why this an important change
gorails.com/episodes/how...

#RubyOnRails #webdevelopment

1 year ago 1 0 0 0

This a web app, viewed on my phone through the browser πŸ‘Œ
I haven't consider any sort of mobile app, would probably go PWA to start with.

1 year ago 1 0 1 0
Post image

Rails `class_names` aka `token_list` helper is great for define #CSS classes in view components or partials.

Docs: edgeapi.rubyonrails.org/classes/Acti...

#RubyOnRails #CodeExample

1 year ago 5 0 0 0
Advertisement

Not a new #AppIdea for me but, an Instagram like clone for specific events like weddings. Guests share photos and videos to an event's timeline.
Could also handle RSVPs.
#RubyOnRails #webdevelopment #buildinpublic

1 year ago 4 0 0 0

We've been using the recipe and shopping list feature for a few months now πŸ‘Œonly introduced the planner over the weekend so we'll see how it goes πŸš€

1 year ago 1 0 0 0

Meal Planner app finally got it's meal planning functionality

Allows us to add recipes to a day of the week. Already using this to plan this week's meals πŸ˜‹

#RubyOnRails #webdevelopment #buildinpublic

bsky.app/profile/dcyo...

1 year ago 5 0 2 0

I'm sure there's a "better" way, but if we've gotten this far with Homebrew I'm sure we can keep going πŸ˜‚

1 year ago 1 0 0 0

All my projects run on the same postgres version so Homebrew does the trick.
If I have a project on an older version, I'll upgrade - even if that's just making it run locally.
That being said none of my projects do anything "fancy" at the database level.

1 year ago 0 0 1 0
Preview
Galileo AIGalileo Icon

You could get a jumpstart by using some AI tools like www.usegalileo.ai

Has worked well enough to kick off some of my projects - doesn't replace a real human designer though.

1 year ago 0 0 1 0

Now I want to collate my thoughts, check my commits and write up what worked for me.
I'm running a few apps on a single Hetzner box, recently using SQLite, but I do have a couple of postgres apps too.

1 year ago 2 0 1 0

I've been doing this a lot recently, mainly to get better at Kamal and Docker things. Got my latest app deployed very quickly with only a handful of hiccups πŸ‘Œ

1 year ago 2 0 1 0
Preview
Songs on Rails

Who is the genius behind the Songs on Rails YT Channel? πŸ˜‚πŸ€£
#RubyOnRails
youtube.com/@songsonrail...

1 year ago 2 0 0 0
Preview
Combined Mentions with ActionText (Part 2) We're back for part two of the Combined Mentions series. If you missed it, in Part One we setup our application and installed a basic implementation of Trib...

Hey, I ended up backing out of Richer Text, the embeds were a bit too much for my use-case.
I did come across a couple of minor issues, would be happy to chat or raise them on GitHub, whichever you prefer.
I did find your blog post afomera.dev/posts/2022-1... this is what I needed thank you πŸ‘Œ

1 year ago 1 0 0 0
Advertisement

I've predicted that it'll also snow in May next year 🀦

1 year ago 1 0 0 0

Most of these places use Facebook to keep their customers up to date, however the feedback is rubbish and it tends to show up days later than needed.

1 year ago 0 0 0 0

Cafes, restaurants and takeaways in my area often have inconsistent opening times, and sometimes different locations (food vans)

1 year ago 0 0 0 0