Show
Destroy
An entry
Get it down. Make it good. Share it.
Title
Text
Ruby Require vs. Include Include vs Require You must first Require a file/codebase. Requires takes a string as an argument. For example: require "code" load "code.rb" You must then "include" a module or class. Instead of a string, inlude takes a constant for an argument. For example: include ClassName I was looking into the differences between Classes and Modules. A Class can be made into a new instance of an object, but a Module cannot. A Module can contain the same things as a Class, but is used typically to extend of modify the behavior the Class that includes a "Module". Including a Module is often referred to a "mix-in". I found this [link about mixins](http://rubylearning.com/satishtalim/modules_mixins.html) particularly helpful. Now, I can consolidate my custom code into Classes and Modules more appropriately.
Status
idea
draft
release
personal
Series
Part of a Series?
Bitcoin
On Work
Phoenix Trello Tutorial
Civics
Re Email Address
Tags
ruby
×
notes
×
+
Slug
Url
Image 1
Image 2
Image 3
Visible
Date