1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

[Rails Assets] Find the js file name

Posted at

Rails Assets is so helpful and convenient.
But sometimes to find a js file name to write //= require some-js-file in application.js is conofused.

When you use Rails Assets, your Gemfile is like this.

source 'https://rails-assets.org' do
  gem 'rails-assets-hoge'
end

Move to the gem's directory. And show the js file name.

> cd $(bundle show 'rails-assets-hoge')
> ls app/assets/javascripts
hoge.js

Just write the js file name without .js

app/assets/javascripts/applicaton.js
//= require hoge
1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?