Module: ActiveAdmin::AssetRegistration

Included in:
Application
Defined in:
lib/active_admin/asset_registration.rb

Instance Method Summary collapse

Instance Method Details

#clear_javascripts!Object



32
33
34
# File 'lib/active_admin/asset_registration.rb', line 32

def clear_javascripts!
  javascripts.clear
end

#clear_stylesheets!Object



16
17
18
# File 'lib/active_admin/asset_registration.rb', line 16

def clear_stylesheets!
  stylesheets.clear
end

#javascriptsObject



28
29
30
# File 'lib/active_admin/asset_registration.rb', line 28

def javascripts
  @javascripts ||= Set.new
end

#register_javascript(name) ⇒ Object



20
21
22
23
24
25
26
# File 'lib/active_admin/asset_registration.rb', line 20

def register_javascript(name)
  Deprecation.warn "    The `register_javascript` config is deprecated and will be removed\n    in v2. Import your \"\#{name}\" javascript in the active_admin.js.\n  MSG\n  javascripts.add name\nend\n".strip_heredoc

#register_stylesheet(path, options = {}) ⇒ Object



4
5
6
7
8
9
10
# File 'lib/active_admin/asset_registration.rb', line 4

def register_stylesheet(path, options = {})
  Deprecation.warn "    The `register_stylesheet` config is deprecated and will be removed\n    in v2. Import your \"\#{path}\" stylesheet in the active_admin.scss.\n  MSG\n  stylesheets[path] = options\nend\n".strip_heredoc

#stylesheetsObject



12
13
14
# File 'lib/active_admin/asset_registration.rb', line 12

def stylesheets
  @stylesheets ||= {}
end