• 0

your thoughts on preprocessoring for CSS?


Question

I'm pretty good on CSS3 which is an easy thing to learn. Seeing a lot of LESS and SCSS out there. Well never work on them before when I outsource coding for jQuery work done the cas was done in SCSS and fi d it hard to go there and messy. Your thoughts on it.

11 answers to this question

Recommended Posts

  • 0

I love SCSS, it helps keep your CSS organised, especially when it comes to responsive design with various breakpoints. Selector nesting, media query nesting, mixins, variables, sprite generation, colour mixers, inline calculations, etc. all assist you in writing (generating) CSS quicker and since it's just a superset of CSS you can pick and choose which features you use. All SCSS implementations are open source too, so if you want to fix/add features you can.

I've used SCSS in pretty much all of my projects for the last 18 months and haven't hit any big negative points.

 

  On 02/07/2013 at 03:01, Torolol said:

from users standpoint i hates when javascripts modifying the style, as its remind me of those annoying ads.

CSS preprocessors (stylus, sass, scss, less) 'compile' the language into standard CSS before being used on the page, they don't use javascript to modify the style. Well, unless you were to use a javascript implementation, but I don't know why anyone would do that on a live site.

  • 0

Yeah I love using preprocessors, they give coloring possibilities like darken and lighten and grayscale and variables and the best of all, nesting :D

 

sass and scss are both preprocessed and then uploaded on your site so there's no way to know it has been written in those preprocessing codes but less isn't preprocessed before it's uploaded it's being preprocessed by a js file while the webpage is being loaded, I myself like less more since I can use other js code to change the less variables on the go :P

  • 0
  On 03/07/2013 at 15:07, Trollercoaster said:

Gimmicky really. Just another step in the process that doesn't need to be there.

Hmm less really makes it less work instead of more in my opinion, especially when I have clients that wants a lot of stuff chnaged every now and then it's handy since I just have to edit my variables .

  • 0
  On 05/07/2013 at 12:28, Seahorsepip said:

Hmm less really makes it less work instead of more in my opinion, especially when I have clients that wants a lot of stuff chnaged every now and then it's handy since I just have to edit my variables .

Care to document an example?

  • 0

As example your client has a website he wants in certain colors and some darker and lighter tones of it but he's not sure about the color yet and the amount of variations.

@color: green;

.one {
    background: @color;
}
.two {
    background: darken(@color, 10%); //A bit darker
}
.three {
    background: darken(@color, 25%); //A bit more darker
}
.four {
    background: lighten(@color, 10%); //A bit lighter
}
.five {
    background: desaturate(lighten(@color, 10%), 10%); //A bit more desaturated and lighter
}
.six {
    background: fadeout(@color, 50%); //50% transparant rgba value, in this example: rgba(0,255,0,.5);
}

Above we just have made a few color variations which normally take more time in PS or gimp or some other colors pallete program.


And there is a lot more, like calculations and nested coding which makes code a lot more clear to read and easier to write, and you can even nest mediaqueries :D

  • 0

Undoubtedly helpful in a large scale environment with a lot of developers or on an extremely large scale site but for your average site i find it's just not worth it.

I'm a bit of a purist also, i can see the point in LESS/SCSS but i like my CSS to be free from clutter and as it was intended, occasionally i don't have the choice and a preprocessor is used but generally i'll try to do it without.

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Posts

    • Fan Control V230 by Razvan Serea Fan Control is a powerful and versatile portable utility that allows you to monitor, control and customize the fans of your GPU and CPU to keep your machine cool and running smoothly. Fan Control supports a wide range of devices and hardware configurations, giving you complete control over your computer's cooling system. Fan Control backend is mainly based on LibreHardwareMonitor, an open source fork of the original OpenHardwareMonitor. This means that hardware compatiblity is entirely open for anyone to contribute, and doesn't rely on a single developer who may stop caring at some point. Combined with the plugin system, Fan Control is unlocked for many generations of hardware to come. Main features Guided setup process on first launch Save, edit and load multiple profiles Change the theme and color of the application. Multiple temperature sources ( CPU, GPU, motherboard, hard drives... ) Multiple fan curve functions, including a custom graph Mix fan curves or sensor togethers (max, min, average) Low resource usage Advanced tuning with steps, start %, stop %, response time and hysteresis FanControl V230 changelog: Update LibreHardwareMonitorLib (ITE IT8696E lost controls) Update translations Download: FanControl V229 | Installer ~15.0 MB (Open Source) View: Fan Control Homepage | Screenshot Get alerted to all of our Software updates on Twitter at @NeowinSoftware
    • "Conflicts of interest", says the man that put Elon Musk, Mr. Conflict of Interest #1 Himself, in charge of a government agency supervising his own contracts.
    • With our Labor unions, a snowball's chance in hell has more probability.
    • inception horn at max volume every time you copy.
  • Recent Achievements

    • First Post
      EzraNougat earned a badge
      First Post
    • One Month Later
      westDvina earned a badge
      One Month Later
    • Community Regular
      Bern@rd went up a rank
      Community Regular
    • Week One Done
      Joey Solo earned a badge
      Week One Done
    • Week One Done
      Vicente C Alves earned a badge
      Week One Done
  • Popular Contributors

    1. 1
      +primortal
      711
    2. 2
      +FloatingFatMan
      200
    3. 3
      ATLien_0
      163
    4. 4
      Xenon
      130
    5. 5
      wakjak
      110
  • Tell a friend

    Love Neowin? Tell a friend!