4 ms·
When did you learn rails? Would you recommend learning it today?
by peacetreefrog 8y ago
When did you learn rails? Would you recommend learning it today?
- scottfits 8y agono, don't learn ruby on rails today. Companies still use it but I highly recommend using Django or Flask and Python as an alternative if you're starting from the ground up
- benmanns 8y agoWhy?
- mixmastamyk 8y agoBelieve they'd say that popularity of the language is on the upswing rather than down. In a world where JS, Python, and Perl already exist, is there still room for Ruby? (Mention Perl because I believe it might fill some Ruby use-cases, and is generally already installed on Unix.)
- danso 8y agoThis was back in 2009. The NYTimes interactive team had hired folks (Big Nerd Ranch) to hold an in-office Rails lesson, and my boss sent me over to learn with them. While I did have a computer engineering degree, my webdev experience was limited to making elaborate (but poorly-coded) PHP and Flash scripts. I was actually hired originally to be a web producer (mostly tasked with posting stories online and making the HTML proper), but learning Rails not only taught proper web app conventions, but allowed me to build important data projects, such as this one: https://projects.propublica.org/d4d-archive/ https://projects.propublica.org/d4d-archive/ I stopped using Ruby and Rails and opted for Python when I started teaching at university, because I realized Ruby wasn't ideal for teaching novice programmers. But I've recently picked up Rails again for some freelance work and have been delighted at how easy it is to get back into. My sense is that Ruby and RoR are no longer as dominant or competitive compared to Python, but it still seems to be a very high in-demand skill because of all the apps/startups that used RoR from the time I learned it back in 2009. That said, learning RoR was less about having the specific skill on my resume, and more about my first exposure to professional and open-source application development, which I'm embarrassed to say I had virtually no experience with when majoring in computer engineering. Today, I personally would recommend people learn Python and do Django, even though I've personally never used Django myself, but feel confident that it's not much different than my RoR experience.
- atmosx 8y ago> because I realized Ruby wasn't ideal for teaching novice programmers Care to elaborate? I work with both of them lately, consider me a novice programmer since I rarely write anything complex, but which part of ruby is not ideal for teaching? I find the ruby syntax much more self-explanatory than python. An example: recently, I had to use private methods in a python project. I went for the _method() convention, but priv methods don't exist in py.
- gaius 8y agoI find the ruby syntax much more self-explanatory than python. Yes and no. Consider that these are different in Ruby but the same in almost every other language: f(x) f (x) Ever had to debug code that relied on this behaviour? Or had to explain why exactly to someone unfamiliar with yacc?
- danso 8y agoExactly this. People who are new to programming -- and aren't, say, majoring in math -- don't understand or appreciate determinism and exactness. That is, if their "program doesn't work", and unless you intervene as the instructor, they'll try every random thing they find on StackOverflow until their program "works" (i.e. no longer raises an Exception). I love the elegance possible in Ruby syntax, but it allows for way too much ambiguity, and if you don't understand how parsing/interpreters fundamentally work, it will seem like Ruby is as loose and permissable as regular English syntax, which is a huge stumbling block for people entirely new to programming. I admit to slamming my fist on my desk the first time I tried writing Python only to get an indentation error, but Python's explicitness is incredibly helpful in making clear the exactness needed for computation. And Python's design helps prevent many of the kinds of catastrophic/difficult to debug errors that do not throw exceptions in Ruby. For example, the following situations are acceptable in Ruby, but in Python, will raise errors: if x = 9 puts x + 1 # prints 10, because x is assigned to 9 first y = {} z = y["this doesn't exist"] # z is set to nil
- dominotw 8y agolearn machine learning and AI instead of rails now. Rails is 2008-2012.
- wallflower 8y agoTo suggest that someone who would have picked up Rails in 2008-2012 can pick up AI/ML with the same amount of effort borders on ludicrous.
- benmanns 8y agoI learned Rails because it was way better than PHP. I had a colleague show it to me and was amazed at how much simpler things can be when you have your ORM, MVC, templating, configuration all set up in an opinionated framework. As for whether or not you should learn it today - maybe? I think there's still a future for Rails development. It's more of a workhorse now than the Hot New Thing. I think if you're looking for something new, look for things that you (or others) get excited about, because they are way better then the current way. Learning Rails was because it was 10x better than the PHP spaghetti shit that I was personally coding in early 2010s. I think this can apply to a lot of trends. For me, Golang was a much much better way to handle concurrency. Add typing, strong performance, compilation. It's also on an upward trend that I was on the leading edge of. These days I'm learning Rust because I think the borrow checker is an interesting and much better way to handle memory than manually allocating/freeing, pointers, or slow GC. However, who knows if it will take off. Similar things have happened with frontend. From what I understand React is much much better than coding together stuff with jQuery and random plugins.
- Zimbleton 8y agoI wouldn't recommend it today. Ruby/Rails is 10x to 20x slower as a web server compared to web frameworks for languages that were designed to be concurrent like Java (Play), Erlang (Plug, Phoenix), and GoLang (Gin, Martini). Even Nodejs Express is 3x faster. Benchmarks here: https://github.com/mroth/phoenix-showdown https://github.com/mroth/phoenix-showdown One of the core Rails developers José Valim created his own language Elixir built on top of Erlang and web framework Phoenix. Ruby is a beautiful language - well written code can bring a tear to your eye like Haiku. But its not designed for concurrency so you have to bend over backwards to add caching and scale your web server a lot more than other languages. Learning Ruby/Rails and being part of a team that followed Sandi Metz 5 Rules and TDD made me a better programmer in other languages. Most companies are moving towards microservice architure where each service runs separately and can use whatever language makes sense for that service. We replaced our monolithic Rails web app with 20+ microservices, most of which use Golang, some Python and Node and Java. The main web server service renders one html page (about 20 lines!) that simply renders a React app that communicates with our API server (API server router then routes to the correct microservice). We don't need Rails view templates or localisation support as most dynamic websites do this clientside. Doing lots of Javascript in Rails was always clunky and poorly supported until a year or so ago when they caught up and added modules and hot reloading support. We have found Golang very easy to learn, ridiculously fast to compile and run tests and very robust. Google said it was designed for Programmer enjoyment and it really shows.