Module: Jquery::Datatables
- Defined in:
- lib/jquery-datatables.rb,
lib/jquery-datatables/engine.rb,
lib/jquery-datatables/version.rb,
lib/generators/jquery/datatables/install_generator.rb
Defined Under Namespace
Modules: Generators
Classes: Engine
Constant Summary
collapse
- VERSION =
"1.10.17"
Class Method Summary
collapse
Class Method Details
.assets_path ⇒ Object
33
34
35
|
# File 'lib/jquery-datatables.rb', line 33
def assets_path
@assets_path ||= File.join gem_path, 'app/assets'
end
|
.gem_path ⇒ Object
21
22
23
|
# File 'lib/jquery-datatables.rb', line 21
def gem_path
@gem_path ||= File.expand_path '..', File.dirname(__FILE__)
end
|
.hanami? ⇒ Boolean
46
47
48
|
# File 'lib/jquery-datatables.rb', line 46
def hanami?
defined?(::Hanami)
end
|
.javascripts_path ⇒ Object
29
30
31
|
# File 'lib/jquery-datatables.rb', line 29
def javascripts_path
File.join assets_path, 'javascripts'
end
|
.load! ⇒ Object
8
9
10
11
12
13
14
15
16
17
18
|
# File 'lib/jquery-datatables.rb', line 8
def load!
if rails?
register_rails_engine
elsif hanami?
register_hanami
elsif sprockets?
register_sprockets
end
configure_sass
end
|
.rails? ⇒ Boolean
42
43
44
|
# File 'lib/jquery-datatables.rb', line 42
def rails?
defined?(::Rails)
end
|
.sprockets? ⇒ Boolean
Environment detection helpers
38
39
40
|
# File 'lib/jquery-datatables.rb', line 38
def sprockets?
defined?(::Sprockets)
end
|
.stylesheets_path ⇒ Object
25
26
27
|
# File 'lib/jquery-datatables.rb', line 25
def stylesheets_path
File.join assets_path, 'stylesheets'
end
|