Hacker News new | past | comments | ask | show | jobs | submit | xutopia's comments login

I'm currently building an application to launch it soonish. I'm using Rails and doing everything myself (save for the design of the logo, and some input from a friend on UX).

What's more is that I'm building mobile applications using Hotwire Native. I'm a solo developer building 2 mobile apps(iOS and Android), supported by a fully functional web application and done with vanilla Rails with Hotwire Native.

I'm surprised how well Rails ecosystem is suited to do everything nowadays.


I just wish Ruby had something with the widespread adoption of TypeScript. Once a project gets large enough it's really painful not having types

Sorbet and RBS are okay but they don't really compare


The way I describe language types to non-coders inquiring about language selection for a given project is simply “scale matters”… dynamic types provide flexibility at small scale, but can very easily result in chaos at a large scale. Conversely, the structure of static types can feel onerous and restrictive at small scale, but provide robustness and structure at large scale.

If you mean codebase complexity and team size... then yes... types is more helpful with that. But in a small team with a small codebase you don't need types to do really well. I find types helped a lot when multiple teams were responsible for different domain spaces inside different components of a Rails app. I never saw the same advantage in codebases that are much smaller with fewer people.

If you can keep everything in your head, types can feel superfluous. Large projects make that nigh impossible.

In my experience it's exactly the opposite.

I see what you mean but I have never found it to be an issue even in large codebases. Sorbet and RBS have been problematic. Lots of development slows down with these solutions. I wished it had something baked into the language as well but I'm happy without... just following conventions alone has worked really well for me.

Yeah I just can't go back. How fast you can confidently refactor and the improved tooling is the biggest thing for me

You can do fine without them - Basecamp proved that. There's a good reason basically every other Rails company eventually moved to static typing though


Jake Zimmerman wrote this excellent blog post[1] on the current state of Sorbet.

I was impressed at recent changes in the Sorbet syntax but also with the proposal that we make code comments available to the ruby VM.

That would allow Sorbet to adopt the rbs-inline comment syntax for both runtime checks and static analysis.

So there does appear to be a way forward on this, which is pretty exciting.

1. https://blog.jez.io/history-of-sorbet-syntax/


This is a great presentation/article, thank you for posting it since I haven't seen it go by elsewhere.

What holds me, personally, from Sorbet is the fact that it tries (unwillingly) to dictate which features of Ruby are "bad" by not supporting them - specifically, "prepend" and Refinements. Now, Refinements I havent' seen used in the wild, but "prepend" I use the living hell of - both when designing modules and when overriding other libraries (with moderation, and when I do it is gawddam' well necessary).

While I can appreciate opinions, I am not really motivated to adopt a tool which snaps me on the fingers because I use the tools I know the utility of. I am not working at Stripe nor at Shop :-) Another thing I could really appreciate would be ad-hoc interfaces a-la Go - and more support for duck-typing in general. Maybe I missed this in Sorbet, but it seemed the idea was to "inherit like you are told to and shut up" - which is not how truly great things can get done in Ruby, at least in my experience.

Interesting to see where Sorbet goes in the coming years - and stoked for more RBS/Sorbet interplay!


Why? No one's stopping you from, say, using a Rails API and React front end.

Because I would prefer the Rails side to have good support for static typing

Just curious, why?

I like static typing when it gives me a 100x speedup (Java, C++, Haskell, whatever), but not solely for the sake of it...


I get the most value from it when it comes to refactoring

What made you choose Hotwire over Capacitor?

I started my app using Rails and Hotwire/Stimulus and honestly finding myself way more productive than I did with more JS heavy options. Everything just works so nicely together in the Rails world.

I can't recommend this author enough. Project Hail Mary and The Martian are amazing works of science fiction. Project Hail Mary is actually amazing as an audiobook.


I enjoyed The Martian (novel and movie) but I didn't care for Artemis or Project Hail Mary. I thought the characters and dialogue were fairly weak, even though the underlying ideas were clever. Also I thought that "main character amnesia" was a frustrating plot device (in PHM).

Overall, his authorial voice reminds me a lot of YouTube hosts? Perhaps that's just the cultural moment we're in.


His stories are always extremely clever and he has an insane sense of rythm. But I hate his style, it reads like a giant Reddit post. My wife asked why I kept complaining about this book I couldn't put down.


I had similar feelings for PHM, but it was hard to put a finger on why. I enjoyed it well enough to make it to the end, but I think I have a limited appetite for his "authorial voice". I read it directly after The Bone Clocks and remember thinking I missed David Mitchell's "voice" and wishing there were a way to experience books through another author's voice. Outside the copyright concerns, this could be an interesting use case for AI, a cover band for literature. It's definitely the only way we'll ever get Wes Anderson Star Wars


I like his concepts, and his stories, but agree about the characters. Every single one of them talks like a snarky sarcastic white dude. All the side characters in The Martian, the teenage girl in Artemis, and the rock alien in Project Hail Mary, all speak in the same voice, that of a jokey middle-aged dad.


Some other recommendations depending on what you liked about The Egg/Project Hail Mary/The Martian:

If you liked explorative / conceptual Sci Fi, more for the thought exercise than anything else:

- Exhalation by Ted Chiang. A collection of scifi short stories that are quite thought provoking. Some sprinklings of religion in some of them.

- The Illustrated Man by Ray Bradbury. A classic, also a short story collection. Golden age scifi.

- Project Hieroglyph. A collection of authors that partnered with Phd students to write short stories based on their research papers. Great concept with great stories.

If you liked Andy Weir's focus on engineering/building:

- Bobiverse series by Dennis E. Taylor. A man uploads himself into a Von Neummann probe and replicates himself to play Factorio among the stars.

- Destiny's Crucible by Olan Thorensen. MC gets sent to an alternate earth in a technological past, and attempts to re-introduce modern technology and build industry.


I went into Project Hail Mary knowing nothing beyond it was from the author of The Martian. It may have been the most enjoyable reading experience I've ever had.


I'm in the back third of Project Hail Mary now. Same. I went into it blind and it's great. I did have to take a break in the very beginning just because dealing with my own existential crisis was enough that I didn't need a fictional one ... lol?

Artemis was good too.


[flagged]


Then why are you in this thread


I will never fail to be amused by people here and on Reddit who spend their calories diving into discussions about things they don't like to tell people they don't like them.


If they actually take the time to write a thoughtful critique, that's one thing. But just saying they don't like something really doesn't add to the discussion.


You are absolutely correct, Mary is amazing as an audiobook. Loved both his books.


Funny coincidence - I just finished the Project Hail Mary audiobook this morning and loved it.

Any recommendations for the next audiobook?


Mickey7 is pretty good if you enjoyed Project Hail Mary. Alternatively, the Murderbot series.


I can 2nd the murderbot series.

Also there bobiverse series is great IMHO


On the vein of similar books, in the late 80s, early 90's a read a science fiction anthology that had more or less the same exact story as Mickey7.

Humans discover a place (I think on Mars), built by Aliens, but it's a deathtrap. So they send someone in to navigate the deathtrap using a clone, and a sort of remote control (something like Avatar).

Each time the clone dies, the person piloting it survives, but has gained the memory of what went wrong, and can try again (kind of like Edge of Tomorrow).

The point of the story is the very end, when the pilot makes it fully through the space.

Has anoyone every heard of this storay and know the name/author? (Bonus points of you know the anthology as well)


I answered my own question! It's called Rogue Moon (1960) by Algis Budry, and was in the anthology The Science Fiction Hall of Fame, Volume Two


The main thing keeping me from the murderbot series is the value prop. They are incredibly short which doesn’t play as well with a credit based purchasing system. For seven credits I get a little over 20 hours of content. Project Hail Mary is 16 hours for one credit.


Just finished Mickey7, lot's of fun. I gotta see the movie now.

LOVE the Murderbot series, highly recommend.


[flagged]


18 years ago you wrote an essay which shares the general premise with this short story: https://charmonium.com/infinite-reincarnation/

What exactly do you mean by "plagiarizing" here? Sharing the basic idea?


The Canadian economy is not doing so poorly that it could explain a 70% drop nearly overnight.


This by a mile.

Anecdotally, by buddy runs a few bnb’s in cottage country in Ontario. Bookings for the summer are mimicking that pandemic surge in 2020/21. It’s wild out there right now.


The job market for one is brutal. It’s all interconnected. Its been leading up to this for some time.


The context is that Canadian airlines aren't seeing 70% drops in forward bookings anywhere else and WestJet is adding routes to Europe to replace US flights...


Then why now all of a sudden instead of 6 months ago?


You can look at the documentation on their web site too: https://picoruby.github.io


I can't imagine having to build a frontend in React... I'm doing everything from mobile app to extensive frontend using Rails... no React anywhere. Just plain vanilla Rails and it's been a godsend!


Rubyists understand it perfectly. It's common practice for us.


I wished that this were a documentary in video format. It is fascinating what this article is saying.


The good thing about these frequent upgrades by them is that you'll soon be able to just get a new device whenever you need it, without worrying about upgrade cycles.


I can't help but feel that Rails is having a comeback now. Lots of people building really cool projects like this one popping up. The stack is insanely good for doing everything I need to do and the Hotwire Native stuff is starting to get more and more solid every day.


Adding an anecdote I'm one of those newcomers having rediscovered rails a few months ago after all the buzz around version 8.

I just got done porting https://www.skatevideosite.com (and our custom admin panel) from sveltekit/fastapi to Rails and I'm stoked on the results so far.

I need to write up my experience about the rewrite, having a blast so far.


wow this is the first i've seen someone port from sveltkit to rails. can't wait to read that writeup


drop me an email, hn at skatevideosite.com, and I'll be sure to message you when it comes out :)


I still prefer Vue3 with Vite over hotwire and stimulus. It is much easier to be productive on frontend if you need anything beyond usual CRUD


Second this - here is a guide for good setup for this https://mailsnag.com/blog/rails7-vuetify3/


Vue3 is great. Also Svelte5. But I’m not sure I would use either of those for an email. And sometimes you don’t need any interactivity in the frontend and server-side-rendered HTML can be a good option.


Wonder if there is some data that backs up this claim


LiveView is the brainchild of Chris McCord. He did the prototype on Rails before getting enamoured by Elixir and building Phoenix to popularize the paradigm.

LiveView is amazing and so is Phoenix but Rails has better support for building mobile apps using Hotwire Native.


Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: