lib/cm_admin.rb in cm-admin-0.9.1 vs lib/cm_admin.rb in cm-admin-1.0.0

- old
+ new

@@ -12,21 +12,26 @@ mattr_accessor :layout, :authorized_roles mattr_accessor :included_models, :cm_admin_models @@authorized_roles ||= [] @@included_models ||= [] @@cm_admin_models ||= [] - class << self + def webpacker @webpacker ||= ::Webpacker::Instance.new( root_path: CmAdmin::Engine.root, config_path: CmAdmin::Engine.root.join('config', 'webpacker.yml') ) end def configure(&block) - instance_eval(&block) + # instance_eval(&block) + @config ||= Configuration.new + yield(@config) + end + + def layout end def config @config ||= Configuration.new end