Reputation: 63647
How can I print out an image tag to a Rails asset in javascript?
If I have an image at /assets/images/my_image.png, the following will show an image in development, but not in a production.
$('.myImage').html('<img src="/assets/images/my_image.png">');
Upvotes: 0
Views: 252