Categories
Software Technology

Before you Learn Rails

Since I started learning Rails I’ve often been asked “is Rails hard to learn?” A lot of times this is by people who don’t know any other programming language or even HTML. The answer to that question is a little more complicated than a simple yes or no. Rails isn’t necessarily hard to learn, but a lot of other stuff comes along with it. Here’s the list I came up with of the things you’ll have to learn to write web applications in Rails:

  • The programming language Ruby
  • Obviously Rails itself which involves learning the Model View Controller (MVC) design pattern (or collection of patterns) and the way these are implemented in Rails, the file structure of Rails and the syntax and domain specific functions Rails adds to Ruby including how to write templates using RHTML. Rails is composed of several frameworks, ActiveRecord, ActionPack (which includes Action Controller, Views, Mailer and Web Services), each of which have to be learned.
  • How to use Rails plugins, components, Engines Ruby gems etc. This includes how to get them installed along with learning enough to know when (or if) and how to use them.
  • AJAX, Prototype, JavaScript and RJS. You may not have to learn JavaScript (which itself is a full featured programming language) but you’ll definitely have to be comfortable with using it to some degree.
  • What web services are and how they work.
  • How to create and use relational databases.
  • Basic SQL, at least enough to know what is happening behind the scenes with ActiveRecord. There almost certain to be times when some SQL will have to be written out for reports, optimization etc., so knowing at least some SQL is important.
  • Having enough of a knowledge of FastCGI, Mongrel and WebBrick to make a decision about which (or which combination) to use to deploy the application.
  • Apache, specifically how to configure it to work with either FastCGI or Mongrel. Alternatively Lighttpd or another web server.
  • Rake, Generators and Capistrano and remote deployment.
  • Database migrations.
  • Testing web applications (which admittedly I haven’t done much yet).
  • A basic knowledge of web application security.
  • How to set up and use SVN repositories. If you’re new to source code versioning this can take awhile to get used to.
  • It may be necessary to learn a new IDE (RadRails) and/or a new text editor (TextMate).
  • As with any new programming language, you’ll have to learn to get Rails installed. In my case this meant figuring out how to do it on my personal computer (a Mac), my work machine (Windows XP) and the servers (Linux). None were too difficult but they all had their idiosyncrasies that had to be dealt with.
  • If you don’t already know it, you’ll need to learn XHTML and CSS

Some of the things in that list are quick and easy to learn, others will take time and practice (I’m still working on a lot of them). If you’re thinking about learning Rails, this list isn’t meant to discourage you, just help to make you aware of what you’re up for.

Technorati Tags: , ,

-advert-

Computer-Training.jpgIf your looking for IT certification or even A+ training then explore your options with CBT Planet. Expand your horizons and learn more about how to use a computer or run your business on a computer. CBT Planet.

-advert-

10 replies on “Before you Learn Rails”

This is a really good article that sums it up quite nicely. It’s like any other framework a powerful glue that mixes interesting ideas with existing technology.

Here’s the list I came up with of the things you’ll have to learn to write web applications in Rails:

I disagree with “have to learn” part. I definitely don’t need to know Ajax or js to build a web app.

To sum it up further, if you’re not a developer, then, yes, it will be hard to learn. It will require a good deal of your time. You may be able to throw something together after a tutorial or two, but I doubt it would be something that could be called an application. If you are a developer, it should be no more difficult than learning any other development framework.

very illuminating…

my own experience was that it was not straightforward to install rails on a windows pc

cant remember all the issues, but the point is, if it doesn’t just insall clean, no fuss, i’m not interested

those who pride themselves on how they can tweak and hack to get to square one completely miss the point

i prefer to spend my time on productive activity, not fighting my toolset

the ruby/rails guys would to well to take a cue from apache: i can download apache, tomcat, xerces, whatever, unzip, and it just works out of the box; same for mysql, php, the jdk, and even stuff form the evil empire in redmond usually installs and runs out of the box

then i can begin what i really care about, which is programmming/development, not f—–g with configuration and installation because of the amateur hour mentality of the so-called ‘alpha geeks’

This list is good but I’d actually like to see it ordered a bit differently. I feel that there are things you just NEED to know first, and then things that are good to know, that you can pick up later.

Needs (in order of what you should know first)
HTML
How forms and requests work on the web
How web apps work (request/response/session)
CSS
Basic SQL
RDBMS concepts
MVC pattern
Ruby

Good to know stuff
Test-driven development theory
Agile methodologies (Rails will help you learn them)
Javascript
Graphic design
Web standards / semantic markup
Apache / Lighttpd / clustered deployment
*how* to deploy
Linux / Unix

Just my .02… and keep up the good work! Nice stuff.

@floidster:
Installing Rails on Windows couldn’t be easier.. the instructions on the official site are basically for Windows users…

install one-click ruby
gem install rails –include-dependencies

That’s it. I’ve heard of people having problems with other methods, but that one works.

/spends a lot of time on Windows.

For someone with no programming experience who just wants to put up a web application, I’d say that Rails is the wrong platform.
PHP would be much faster to learn and you’d get faster results.
My feeling is that Rails still requires you to be a hacker in order to take full advantage of it. That may change in time – with the huge growth of the Rails community and the interest it receives. Nevertheless, for now, someone with zero or little knowledge, who just wants a simple dynamic website would be better off with a more mature platform such as PHP, that would allow him or her to cross off quite a number of points in your list as unnecessary.

Comments are closed.