Sha256: fdf007f4083240e8bf96ad973c141b6d40df97efaaba4d2147271e32841bb53b
Contents?: true
Size: 882 Bytes
Versions: 23
Compression:
Stored size: 882 Bytes
Contents
module Faalis module Extension # This module provide basic functionallity of a Faalis extension # to a rails engine. # It should be included in engine of all the Faalis extionsions module Base def included(base) extend ClassMethods end class ClassMethods def register_extension(name, klass) # TODO: Replace this mechanism with more elegant one # For example use [] method or someting Faalis::Extension.extensions[name] = klass end # This method tells faalis that this extension will override # the generators templates of faalis from `template_path` location def override_generator_templates(template_path) send(:define_singleton_method, 'generator_templates_path') do template_path end end end end end end
Version data entries
23 entries across 23 versions & 1 rubygems