- Searching and filtering: construct the where clause in the query builder part of the code.
lol_dba: Gem to find which columns should be indexed.
Rails.application.eager_load!– loads all railties.
ObjectSpace.each_object(Module): gets all currently loaded objects.
Pomodoro.descends_from_active_record?is a thing.
Pomodoro.reflectionsto see the
has_many, etc. relationships.
ActiveSupport#each_pair: Calls block once for each key, passing the key-value as parameters.
ActiveRecord::Base.indexes('books')to list all the indices.
- Don’t put things in the app directory that you don’t want to load anyway.
wheremethod in AR returns a proxy object.