CSS assistance with Ruby

Hey there,

New Ruby dev is in need of assistance.

Does anyone know how to set up Materialize CSS with Ruby I am following a tutorial, and the steps for adding the materialize CSS library into Ruby didn’t work for me, I get hit with this error

/Users/DanielSkies/.rvm/gems/ruby-3.0.0/gems/sass_rails_patch-0.0.2/lib/sass_rails_patch.rb:3:in `<main>': uninitialized constant Sass (NameError)
Did you mean?  SassC

The Ruby app automatically came with application.css in the assests/stylesheet/application.css like this. However when I change the extension to what the error is asking for I get hit with an error.

in the application.css I did add this @import "materialize"

and of course, I did bundle install and also gem individual install.

Anyone know how to do this really lost.

Thank you

Are you adding sass and sass-rails gems? Try adding them and run bundle install again.

gem 'sass'
gem 'sass-rails'
1 Like


Thank you for replying I found the solution to my problem with trial and error. Sometimes you have to take a step back for things to work.

It turns out the wrong version of MaterializedCSS with installed. I updated it to the current and imported the correct gems.

1 Like

Exactly, One back steps make multiple changes in your work. I also get this in my life and solve multiple queries to making mind set with this.
AM APk for ios 2022