Jamie Balfour

Welcome to my personal website.

Find out more about me, my personal projects, reviews, courses and much more here.

What CSS still needs and where Sass has it right

What CSS still needs and where Sass has it right

There are a ton of missing features in CSS and even more than need standardised. I have tweeted some very popular ideas into the #BetterWeb hash tag on Twitter, because I personally believe that the web could become better with some of these features. This article is not a list but my two favourite possible options to come to CSS.

Variables

CSS would benefit from variables temendously. Although there are alternatives to CSS that hammer it in every way possible, they are fundamentally the same thing. I'm particularly talking about Sass or Syntactically Awesome Style Sheets. Sass offers variables.

There are two ways to do this in CSS. The first is more complex in that it requires some server side language to precompile the CSS and distribute it.

The second way is to use Sass and then convert it to CSS using some online converter such as the one found here. This such alternative seems more reasonable.

My argument is why is it that still not being implemented into CSS?

I read something interesting on CSS3 the other day and it went something like this:

Whilst Microsoft, Google and Firefox have all released new browsers and programming languages, CSS2 has still not even been fully implemented.

CSS does tend to have a very long adoption time, so even if variables are thrown in, it will take some time before they are going to be in the browsers that view the web pages. This is one of it's biggest issues of CSS implementation.

CSS reflection

There is absolutely no doubt that CSS is getting closer to being it's own markup for programming.

The difference between CSS and a programming language is fundamentally that it only specifies what to do with some element in HTML. However, CSS is now getting more like a programming language by adding features such as the :before and :after selectors as well as @media queries that have been added (these represent conditional statements, a fundamental of a programming language).

One thing that has been semi-implemented is the CSS reflection tool. It can be added to certain browsers using a prefix, such as WebKit which has the -webkit-box-reflect property. Of course this is prefixed to WebKit, so no Firefox and so on. The lack of consistency in CSS is one of it's biggest flaws. This article describes CSS reflection well.

But, do you think this is something that should be in CSS? I mean reflection is very much a program on it's own. Tell me what you think by commenting below.

Posted by jamiebalfour04 in The Web
css
sass
ideas
Comments
Powered by DASH 2.0
Scan and keep for the latest article or review every time!
https://www.jamiebalfour.scot/redirect/action/latest-article/