Skip to content

Instantly share code, notes, and snippets.

@alfie-max
Created October 23, 2017 15:29
Show Gist options
  • Save alfie-max/98ae9aeb8bee273b6346e3414a24b7b5 to your computer and use it in GitHub Desktop.
Save alfie-max/98ae9aeb8bee273b6346e3414a24b7b5 to your computer and use it in GitHub Desktop.
module Foo
def self.included(base)
base.class_eval do
def self.method_injected_by_foo
...
end
end
end
end
module Bar
include Foo
def self.included(base)
base.method_injected_by_foo
end
end
class Host
include Bar
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment