Categories
- Active Record
- Active Resource
- Active Support
- Administration
- Ajax
- APIs
- Authentication
- Authorization
- Background Jobs
- Caching
- Code Walkthrough
- Controllers
- Debugging
- Deployment
- eCommerce
- Forms
- Mailing
- Models
- Performance
- Plugins
- Production
- Rack
- Rails 2.0
- Rails 2.1
- Rails 2.2
- Rails 2.3
- Rails 3.0
- Rails 3.1
- Rails 3.2
- Rails 4.0
- Refactoring
- Routing
- Search
- Security
- Testing
- Tools
- Views
Pagination with Kaminari
If you need pagination in Rails 3 try out Kaminari. It is a clean, flexible solution which uses scopes to flow nicely with Active Record queries. Did I mention it also works with Mongoid?
(8 minutes)
Testing JavaScript with PhantomJS
PhantomJS allows us to test JavaScript without going through a browser window. Here I show how to do this using Capybara and Poltergeist. I also give some tips on handling database transactions and skipping javascript tests.
(10 minutes)
Active Record Reputation System
If you need to calculate an average user's rating or sum up a number of votes, consider using the activerecord-reputation-system gem. Here I will cover the basics and also briefly present a from-scratch solution.
(10 minutes)
will_paginate (revised)
Almost every Rails application needs pagination, and will_paginate is a great way to go. Here I show you how to set it up, customize the way it looks, and see how it compares with Kaminari.
(6 minutes)
Hstore
With hstore you can add schema-less data to PostgreSQL. This allows you to store model attributes without creating separate database columns. Watch how to do this using the activerecord-postgres-hstore gem.
(10 minutes)
Messaging with Faye
Faye is a subscription/publishing server which makes it easy to do push notifications within a Rails app.
(13 minutes)
Simple OmniAuth (revised)
OmniAuth makes it easy to do user authentication through a third party provider such as Twitter or Facebook. Learn a simple approach in this episode.
(11 minutes)
Bullet
Bullet will notify you of database queries that can potentially be improved through eager loading or counter cache column. A variety of notification alerts are supported.
(6 minutes)
Squeel
Squeel provides a comprehensive DSL for writing SQL queries in Ruby. It is built upon Arel giving you access to many of its powerful features.
(9 minutes)
More on Twitter Bootstrap
This episode continues on the Twitter Bootstrap project showing how to display flash messages, add form validations with SimpleForm, customize layout with variables, and switch to using Sass.
(12 minutes)