Reputation: 21
I am trying to integrate components from multiple websites into my own Rails website. Their images, CSS files, and JavaScript files are numerous and scattered in deeply nested directories. If I copy their folders into the 'app/assets' folder, I will get something like this:
app/assets/website1/a/b/c/d/image1.jpg
app/assets/website2/e/f/g/style.css
app/assets/website3/h/i/j/k/custom.js
If I try to reference the above items with:
<img src="/app/assets/website1/a/b/c/d/image1.jpg">
<link rel="stylesheet" href="/app/assets/website2/e/f/g/style.css">
<script src="/app/assets/website3/h/i/j/k/custom.js"></script>
respectively, they will not load at all. I would greatly prefer to use relative paths because using the asset pipeline would be a nightmare with such deeply nested directories. Is what I am describing even possible?
Upvotes: 0
Views: 397
Reputation: 830
Have you tried disabling the asset pipeline in config/application.rb by adding the following line to it ?
config.assets.enabled = false
Havn't tested it. Let me know if it works.
Upvotes: 1