...or an explanation for anything here, tailored to what you already know. Just ask. π Rails Guide: Active Record Query Interface β the reference for everything on this card; read Scopes and...
...Eager Loading Associations closely π Battling N+1 queries in Rails β recognizing N+1 in the log and the tools that catch it (2024) π Rails loading patterns: eager, lazy and strict...
This means Basecamp migrated from the first Rails release up to the edge one. So how come people say so frequently how hard is to update their applications from Rails...
...to Rails 2.2? And the answer is simple: plugins...
Now supports RSpec 3 and Rails 4 Drops support for state_machine, which has some issues with Rails 4 and isn't actively maintained
It is common in Rails 3.0 applications that you want to provide default views for a group of controllers. Letβs say you have a bunch of controllers inside the...
...for Admin::PostsController and βapp/views/admin/posts/index.html.*β is not available, it should then render βapp/views/admin/defaults/index.htmlβ. Since Rails 3.0, we have a new abstraction called resolvers that holds the logic to find a...
...ten screens, and soon the same twelve lines of HTML live in ten places. Rails partials are the first tool against this; ViewComponent is the second, for components that carry...
...for anything here, tailored to what you already know. Just ask. Partials π Partials in Rails views β our card: how a partial exposes its API through locals and a yielded block...
...sure not to mess with that. Related cards If you are using Ruby on Rails, a use case / implementation might look like Rails 3: Sending tempfiles for download.
...Sass and Less files, so the theme can easily be integrated into your usual Rails application. Implements only Bootstrap features which means that some Material stuff is missing, but also...
...lists, links, images and forms. Everything you build from here on attaches to it β Rails renders HTML, your CSS selects it, your JavaScript walks it. Important Work on this lesson...
...each exercise, inside the exercises repository. These are plain .html files β no server, no Rails yet. Open them in your browser with file://. Tip Your agent should work in the...
The same applies to files in Carrierwave. Variant: Deliver attachments through Rails The first way is to store Paperclip attachments not in the default public/system, but in...
...can be configured like this: class Note < ActiveRecord::Base has_attached_file :attachment, :path => ":rails_root/storage/:rails_env/attachments/:id/:style/:basename.:extension" end To link to the protecting controller actions...
These two models can be used to access the posts and associated comments of a WordPress database.
Do that for noble reasons only.
...is (or will be) a best effort semi-static verifier for your Ruby on Rails projects. Delivered as a Ruby gem it provides a shell command task "railscheck" that you...
...can run against your Rails projects to test for a number of typical bugs, potential problems and inconsistencies...
Finish the remainder of the ActiveModel todo list (observers, callbacks, validations, scoping, and serialization) in addition to associations. Also wire...
Asynchronous JavaScript and CSS, also known as CSSHttpRequest, is a method of URI-encoding data in 2KB chunks split over...
How to rescue a project without losing your mind.
Here are eight things my team has found to be true after working with Cucumber for about 6 months.
hat's the dirty little secret of our industry; green screen apps are usually pretty darn fast. They aren't...