Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Undefined method 'assets' when loading the application #16

Open
texpert opened this issue Feb 27, 2018 · 0 comments
Open

Undefined method 'assets' when loading the application #16

texpert opened this issue Feb 27, 2018 · 0 comments

Comments

@texpert
Copy link

texpert commented Feb 27, 2018

On Rails 3.2.21 I got:

Uncaught exception: There was an error while trying to load the gem 'activeadmin_hstore_editor'.
Gem Load Error is: undefined method `assets' for #<Rails::Engine::Configuration:0x007fa71b32d718>

Changing this line to an initializer, helps (think it is better to extract this to a separate initializer):

      initializer :active_admin_hstore_editor, :group => :all do |app|
        app.config.assets.precompile += %w[img/jsoneditor-icons.png]
      end

Besides, registering the javascript and stylesheets in the ActiveAdmin initializer doesn't properly load at least he stylesheets - had to require them as earlier, as usual.

wongy91 pushed a commit to coingecko/activeadmin_json_editor that referenced this issue Oct 10, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant