Rails' CurrentAttributes considered harmful - Ryan Bigg
22-Jun-2017 3798
Very briefly, it makes program state unpredictable.To elaborate, imagine you have a couple of objects that both use the same global variable. Assuming you're not using a source of randomness anywhere within either module, then the output of a particular method can be predicted (and therefore tested) if the state of the system is known before you execute the method.
Rails' CurrentAttributes considered harmful - Ryan Bigg #ruby #rubydeveloper #rubyonrails #Rails' #CurrentAttributes #considered #harmful https://rubyonrails.ba/link/rails-currentattributes-considered-harmful-ryan-bigg