Class: Foliate::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/foliate/config.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeConfig

Returns a new instance of Config.



15
16
17
18
# File 'lib/foliate/config.rb', line 15

def initialize
  @default_per_page = 10
  @page_param = :page
end

Instance Attribute Details

#default_per_pageInteger

Default number of records to allot per page. Defaults to 10.

Returns:

  • (Integer)


7
8
9
# File 'lib/foliate/config.rb', line 7

def default_per_page
  @default_per_page
end

#page_paramSymbol

Name of query param used to indicate page number. Defaults to :page.

Returns:

  • (Symbol)


13
14
15
# File 'lib/foliate/config.rb', line 13

def page_param
  @page_param
end