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

Can't override assets/images/noimage/plp.svg #12

Open
mrbrdo opened this issue Mar 23, 2022 · 3 comments
Open

Can't override assets/images/noimage/plp.svg #12

mrbrdo opened this issue Mar 23, 2022 · 3 comments

Comments

@mrbrdo
Copy link
Contributor

mrbrdo commented Mar 23, 2022

If you put your own assets/images/noimage/plp.svg in your project, it will not override the one from this gem, on PRODUCTION (assets:precompile). It works on development.
Sprockets pick up both assets but they put the one from the gem in the asset manifest instead of the one from the app, which should normally have priority.

@sumanawal
Copy link

I am also facing the same issue with production. Already tried with

  1. Clearing cache from the admin -> configuration
  2. rake assets:precompile
  3. rake assets:clean

But no luck. Anyone with the good suggestion to resolve this issue?

@mrbrdo
Copy link
Contributor Author

mrbrdo commented Feb 14, 2023

@sumanawal my workaround is to put this code at the end of config/initializers/assets.rb:

Rails.application.config.assets.precompile.delete("manifest.js")
Rails.application.config.assets.precompile += %w( manifest.js )

But someone should really look into why this is happening.

@sumanawal
Copy link

Thanks @mrbrdo , it works for me 👍

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

2 participants