This question already has answers here:
What's the difference between SCSS and Sass?
(17 answers)
Why use Sass (not SCSS)? [closed]
(4 answers)
Closed 8 years ago.
I have seen a few sass compass tutorials. However, I am having to tweak a sass file from someone else and I can not find out what they did. I do not understand what the + symbol is doing here. I want to say it is similar to the # sign but I can ot find anything that explains it. It is related to singularity? compass?
/* Main */
#main
+tablet-wide
+grid-span(18,1)
+desktop
+grid-span(24,1)
If you know of a good explanation or link please share. Trying to learn and reverse engineer at the same time.
Thanks
Related
This question already has answers here:
How can I override Bootstrap CSS styles?
(14 answers)
Customizing Bootstrap CSS template
(9 answers)
Closed 4 years ago.
I worked with bootstrap many times and usually I'am creating other style file where I'am overwriting bootstrap classes. I think it's better way to do this. I am also get annoying when I have too much code which I actually don't use in bootstrap source.
What's the best way to overwriting bootstrap classes and remove this parts of code which actually is not needed from bootstrap sources?
One very common way is to use the Boostrap Sass implementation and set variables to define many of the styles. This prevents many css 'overrides' and usually results in much less css code.
You can also pick and choose which Bootstrap components to include (via #import) in the compiled css:
https://getbootstrap.com/docs/4.0/getting-started/theming/#importing
https://getbootstrap.com/docs/4.0/getting-started/theming/
This question already has answers here:
Change indentation in Sass
(3 answers)
Closed 7 years ago.
Is there a way to have sass output with tabs instead of spaces?
I know there is the classic argument of spaces but I have a requirement that all my css needs to be indented with tabs before checked in to source control.
Any ideas?
As mentioned by manishie (and his link), there's not built-in way to change how the outputted CSS is indented. The only way is to run it through a separate tool (like Grunt) to "correct" the indentation as you see fit.
This question already has answers here:
Twitter Bootstrap Customization Best Practices [closed]
(7 answers)
Closed 8 years ago.
I have downloaded Twitter Bootstrap from http://getbootstrap.com/customize/
and now I would change some proprieties such as #body-bg or #navbar-default-bg.
Before Bootstrap, I used Zurb Foundation and I changed "foundation_and_override.sass" file. Is there something similar for Bootstrap?
My project is on Ruby on Rails
Check out this similar question. It shouldn't matter which exact file you put it in.. all the css will get compiled in your assets directory in rails.
Twitter Bootstrap Customization Best Practices
You can use this bootstrap gem in Rails, it's well maintained and up to date. The variables are defined here, so you know which value to set before your #import 'twitter/bootstrap' statement as shown in the Readme.
I'm using this exact same approach and am quite happy with it.
This question already has answers here:
Closed 11 years ago.
Possible Duplicate:
Create a variable in .CSS file for use within that .CSS file
I heard about that we can declare/define variable in CSS and use them like global variables like this:
#nice-blue: #5B83AD;
#header { color: #nice-blue; }
So anyone knows how to use them?
For that you need to use Less or Sass which are CSS Dynamic languages.
here's some comparison between both technologies.
You need to use something like SASS
http://sass-lang.com/#variables
or Less
http://lesscss.org/
There is a language written on top of CSS which make use of variables like you asked, it's called LessCSS
This question already has answers here:
Closed 11 years ago.
Possible Duplicate:
Tool to identify unused css definitions
I have quite big CSS file, that already contains style definition for classes/elements that are not used by markup any more.
It is possible to find those quick?
You can use the Firefox extension Dust-Me at http://www.sitepoint.com/dustmeselectors/.
you can get the Dust-Me Selectors plug in for Firefox to test pages individually or spider a whole site.