Sha256: 73406151e34bc243b0f333c2e784efc3489fc3d9d861ac2bce1a64f13e32dbe5
Contents?: true
Size: 1.28 KB
Versions: 4
Compression:
Stored size: 1.28 KB
Contents
# encoding: utf-8 begin require 'active_support' rescue gem 'activesupport' require 'active_support' end begin require 'action_controller' rescue gem 'actionpack' require 'action_controller' end begin require 'action_view' rescue gem 'actionpack' require 'action_view' end require 'cells/cell' require 'cells/helpers' require 'cell' module Cells # Any config should be placed here using +mattr_accessor+. # Default view paths for Cells. DEFAULT_VIEW_PATHS = [ File.join('app', 'cells'), File.join('app', 'cells', 'layouts') ] class << self # Holds paths in which Cells should look for cell views (i.e. view template files). # # == Default: # # * +app/cells+ # * +app/cells/layouts+ # def self.view_paths ::Cell::Base.view_paths end def self.view_paths=(paths) ::Cell::Base.view_paths = paths end end # Cells setup/configuration helper for initializer. # # == Usage/Examples: # # Cells.setup do |config| # config.cell_view_paths << Rails.root.join('lib', 'cells') # end # def self.setup yield(self) end end Cell::Base.view_paths = Cells::DEFAULT_VIEW_PATHS if Cell::Base.view_paths.blank? require 'cells/rails' require 'cells/cell/test_case' if ENV['RAILS_ENV'] = 'test'
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
cells-3.3.8 | lib/cells.rb |
cells-3.3.7 | lib/cells.rb |
cells-3.3.6 | lib/cells.rb |
cells-3.3.5 | lib/cells.rb |