Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
=require twitter-bootstrap-static/bootstrap
*/

@import "font-awesome-sprockets";
Copy link

@toomanyjoes toomanyjoes Jul 26, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So this doesn't break for everyone else wouldn't you want to do something like this?

$rails_version: '#{asset-path("config/application.rb")}';
@if ($rails_version < 6) {
  // Import sprockets only if the Rails version is less than 6
  @import "font-awesome-sprockets";
}
# config/application.rb or an initializer

# Set a custom environment variable to indicate the Rails version
Rails.application.config.rails_version = Rails.gem_version

I'm not entirely sure this works as written as it was generated by chatGPT but some author who knows scss syntax better than me could clean it up.

@import "font-awesome";

html {
Expand Down