Ruby on Rails is an open-source web development framework optimized for programmer happiness and maintaining sustainable productivity. Many things are defined by convention, freeing you from having to re-invent things to stay productive.

learn more… | top users | synonyms (1)

3
votes
6answers
5k views

How much Ruby should I learn before moving to Rails?

Just a quick question.. I can never get a definitive answer when googling this, either. Some people say you can learn Rails without knowing any Ruby, but at some point you'll run into a brick wall and ...
0
votes
1answer
519 views

Convention on model names in ruby on rails

I was doing my ER diagram for a rails application I'm about to begin with and there I have an entity called Class News so I'd have a model ClassNew but I don't know if I will have problems in the ...
-1
votes
2answers
479 views

Am I shooting myself in the foot if I use Mercurial for Rails development?

I'm a Rails developer and I prefer Mercurial over Git. However, I know that the Rails community is very pro-Git. So my question is it possible that my choice of version control system would turn back ...
10
votes
3answers
5k views

Rails - Does using partials slow views rendering?

I'm having performance issues on a Rails 3.1.0 application, now I've done dome changes on my queries with AR and so but views still takes too many time to render, I've divided the views, loops and so, ...
2
votes
3answers
118 views

Post-hoc testing in TDD recommended?

I have a personal project that doesn't have robust testing. I had a bit of TDD going on at the beginning, but it quickly became counterproductive as the project details changed dramatically over time. ...
3
votes
1answer
1k views

Rails application - how to optimize/reduce database calls when iterating over a collection

What's the best way to optimize a Rails app where you need to pull info from the database for a collection of items? For example, if I am building an online forum system... I would have a number of ...
0
votes
2answers
245 views

Structuring a rails application with static data

I'm working on a rails application, and so far I've focused on the api and the functionality. But now I'm more and more reaching a point where I will want to add static content, descriptions of the ...
1
vote
4answers
240 views

If I use Ruby Migrations, do I have to use the rest of Ruby on Rails?

I'm currently trying to come up with a database migrations strategy for my organization. This includes getting the database scripts into source control, managing versioning, managing releases to QA / ...
0
votes
1answer
160 views

In rails, what defines unit testing as opposed to other kinds of testing [closed]

Initially I thought this was simple: unit testing for models with other testing such as integration for controller and browser testing for views. But more recently I've seen a lot of references to ...
1
vote
1answer
574 views

rails fake data, considering switch from faker to forgery, any advantages or pitfalls?

With Ruby on Rails I've usually used Forgery for generating dummy data for testing. I've noticed recently that several clients and tutorials are using Faker They both seem fairly similar in use ...
3
votes
1answer
123 views

Rails solution for mobile-specific content filter?

To note, I'm not interested in simply 'hiding' content for mobile devices, I want to filter out that content completely. I'm also not trying to address the issue by building a mobile specific ...
-1
votes
1answer
189 views

One man company looking to expand already built in PHP. Is now the time to switch to Ruby? [closed]

I'm a website owner and I develop in Yii so in short, I think I'm working with more or less the "best" PHP has to offer (e.g. PDO, OOP...etc). My primary website (which is not built in any framework ...
10
votes
3answers
3k views

Safe iPhone app ↔ server communication

What would be the best approach to achieving private communication between my iOS app and its server component? Is having a single unchanging “secret key” baked into the app source enough, or do I ...
11
votes
10answers
803 views

How to convince teammates to use TDD

I am the only person on my team that use TDD. How do I make them to use it? I am annoyed that when I pull, someone's code will break my tests and I am the one who has to fix them. Will using github, ...
0
votes
3answers
243 views

How to deal with social login

In my new web app I'm going to allow social login through Twitter (maybe), Facebook and Google and I'm in search of the best way to do it. Actually I'm using Rails with Devise + Omniauth and this is ...
2
votes
1answer
326 views

Am I experienced enough to learn and develop immediately using Ruby on Rails?

General Question I understand that discussions revolving around questions of this form run the risk of becoming too specific to help others. So, perhaps a better, general question would be: What ...
3
votes
2answers
2k views

Rails and Mongoid best way to implement sharing system

I have to model User and Board in rails using mongoid as ODM. Each board is referenced to an user through a foreign key user_id and now I want to add the ability to share a board with other users. ...
1
vote
1answer
382 views

choosing Database and Its Design for Rails

I am having a difficulty in deciding the database & its structure. Let us say the problem is like this. For my product I have various customers( each is an educational institute) Each customer ...
3
votes
3answers
567 views

Why rails use yaml to config database instead of plain ruby code?

Most of configuration files in ruby such as Gemfile, gemspec, are just ruby code itself. Why database configuration file in rails is the exception?
2
votes
3answers
657 views

Backbone.js, Rails and code duplication

I'm building a web app and I need a JS framework like Backbone.js to work with my backend provided by Rails that mostly return JSON objects after DB queries. Searching on the web I've discovered ...
3
votes
1answer
601 views

Is Ruby on Rails' Active Record an example of Aspect-Oriented Programming?

From Clean Code, about Cross-Cutting Concerns: Note that concerns like persistence tend to cut across the natural object boundaries of a domain. You want to persist all your objects using ...
0
votes
0answers
187 views

Rails Book Suggestions [duplicate]

Possible Duplicate: Is there a canonical book on Ruby on Rails? I'm looking to learn Ruby on Rails. I already have a small background in Ruby and don't really need a book that covers both, ...
18
votes
3answers
1k views

Moving away from .Net to Ruby and coping without intellisense [closed]

I am in the process of trying to learn Ruby, however after spending nearly 10 years in the MS stack I am struggling to get by without intellisense. I've given RubyMine a try which does help however ...
12
votes
4answers
1k views

What did Ruby do right (or was it Rails)? [closed]

Most programming languages have some design decisions that influence their usage and applicability. For example: Python focused on maintainability/readability of code and had indentation be a part ...
2
votes
1answer
2k views

Rails - How to use modal form to add object in one model, then reflect that change on main page?

I'm working on a Rails app and I've come across a situation where I'm unsure of the cleanest way to proceed. I posted a question on SO with code samples and such - it has received no answers, and the ...
5
votes
4answers
1k views

Where to define view-specific data objects in Rails

Background: there are several places in our app where we want to display date-oriented information on a calendar. The event_calendar gem looks nice and has lots of reviews, so it's what I'm planning ...
1
vote
1answer
614 views

Is PHP a more simple introductory language to back-end web development over Ruby on Rails?

I have a program coordinator for a course I plan to teach who wants to change the "Introduction to Web Development" course from using PHP to Ruby (I assume he means Ruby on Rails). His justification ...
1
vote
1answer
815 views

Starting with Ruby on Rails? I see a lot of criticism everywhere. Is it okay to start with Rails now in 2012? [closed]

I have worked on C before and have never tried my hands on any web application creating framework. After some convincing from one of my friends I thought of giving Rails a go. Before starting to work ...
2
votes
1answer
2k views

Rails - to use STI or not…that is the question

Six months ago, I asked a question about modeling data for my app, and received some advice pointing me towards STI (see Rails data model - best practices question for the details). I played around ...
0
votes
1answer
222 views

Client wants to resell the app I programmed [closed]

Not sure if this is the right forum. If it's not, please let me know and I'll move it. So I have been asked by a client to develop a RoR Web App for them. He asked me if the development is their ...
6
votes
4answers
278 views

How viable is it to switch stacks for setting up a startup [closed]

I am currently employed with a company for 2.5 years and I have been working with the .net stack for the entire duration mainly on the MVC framework. I believe I have some cool ideas for a startup but ...
3
votes
2answers
221 views

Managing constants in application

Our application is having 2 parts a web app running ROR and a web service running Sinatra. The application communicates with the mobile device for which we use different constants depending on the ...
16
votes
14answers
2k views

How can I defend Ruby on Rails against customers' not technical opinion?

My customer, a translations business owner, just told me that he has been reading about Ruby on Rails and told me that "there are more PHP guys around there" and "it seems the community prefers it". ...
4
votes
1answer
202 views

Should I refactor this rails application?

I have taken over the code base for a ruby-on-rails application which relies very heavily on ActiveRecord callbacks to perform domain rules. The application can be compared to a bank application, ...
1
vote
2answers
364 views

Strictly from an employability perspective, what is the best web development framework to learn right now? [closed]

Even though Ruby on Rails seems to be the most popular with the most job openings, is there a compelling employability reason to learn django for example? Maybe because everybody's learning RoR and ...
2
votes
4answers
581 views

Best practices for team workflow with RoR/Github for designer + coder?

My friend and I have started to try to collaborate on some projects. For background, I come from a PHP/Wordpress/Drupal coding background, but recently I've become more experienced with the RoR ...
4
votes
1answer
4k views

Why do people suggest not to use instance variable for views in Ruby on Rails

Why do I hear that it is not good to share instance variables between controllers and views. I kind of like it because I can see immediately via the @ that something is coming from the controller. I ...
-3
votes
1answer
2k views

What are the business benefits of Ruby/Rails to tell a client?

I'm programming Ruby. I'm programming Rails. It's zen, it makes fun and it's cool. But what are the real technical and foremost business advantages of Rails, I can tell a client? I know the ...
4
votes
5answers
2k views

What is a practical way to debug Rails?

I get the impression that in practice, debuggers are rarely used for Rails applications. (Likewise for other Ruby apps, as well as Python.) We can compare this to the usual practice for Java or ...
1
vote
3answers
1k views

Rails generators for subscription and payment processing services?

I've been thinking about making a generator for managing subscriptions with options for a couple different payment processing services, it is something that I would use. Are there any existing ...
12
votes
2answers
886 views

Which tasks should a beginner, intermediate and advanced rails developer be able to complete?

I have been programming ROR for about a year now, and I think I am ready to start working on a project for someone else. The problem is that job postings for contractors don't really tell you which ...
5
votes
3answers
202 views

how to deal with controller mutations

During development process, things are constantly changing (especially in early phases). Requirements change, UI changes, everything changes. Pages that clearly belonged to specific controller, ...
6
votes
7answers
2k views

How to become a professional web developer from a C/C++ programmer? [closed]

I am currently a high school student and know how to use Pascal and C/C++ to take part in competitions such as the Informatics Olympiad. I have learned data structures and many algorithms to solve ...
4
votes
6answers
658 views

Should I keep separate client codebases and databases for a software-as-a-service application?

My question is about the architecture of my application. I have a Rails application where companies can administrate all things related to their clients. Companies would buy a subscription and their ...
7
votes
3answers
444 views

Why decouple view and controller (web)?

Why can't we put them in the same page, like each action paired up with its view? Not using code island, but controller code at top then view code at bottom? What are the problems with this approach? ...
27
votes
2answers
4k views

Does the ActiveRecord pattern follow/encourage the SOLID design principles?

I'm interested in whether ActiveRecord pattern, made famous from Ruby on Rails, encourages or discourages the use of SOLID design principles. For example, it seems to me that ActiveRecord objects ...
-2
votes
1answer
901 views

Devise and Warden

I've been using Devise for a little while, and I've realized it's built on something else called Warden that handles authentication. What does Devise offer me outside of Warden, because I was ...
4
votes
3answers
897 views

How should I go about learning Ruby and Rails? [duplicate]

Possible Duplicate: Is there a canonical book on Ruby on Rails? I really want to change my PHP specialization to Ruby. I have some Ruby/Rails experience, and I've already created a few Ruby ...
1
vote
3answers
863 views

Organising MVC App with virtual model using external API

I am creating a rails app with following constraints It has no database It uses a web API to store and retrieve the data The connection to the web API is via a custom gem. The Gem has a basic ...
2
votes
2answers
3k views

When to use JavaScript instead of Ruby in web development?

Right now I am developing web applications with ruby-on-rails. Sometimes I am having a hard time deciding which language to chose to solve my problems. The difference between HTML,CSS and the ...