Translate

Showing posts with label adam stacoviak. Show all posts
Showing posts with label adam stacoviak. Show all posts

Thursday, June 19, 2014

SASS and Compass

You may have heard the terms Sass or Compass being thrown around recently. Or perhaps you haven't. But regardless of if you've heard about it or not, Sass is something that any Front End Web Developer should have tucked in their tool belt. Basically, Sass is a simpler way of writing CSS. You might ask yourself: "Why would I want to write Sass when I am already proficient in CSS?". Well the answer to that varies depending on who you are.

For me, the feature that really draws me into Sass is cross-browser support. Have you ever wanted to use, for example, a linear gradient, but end up having to find a gradient generator, or check CanIUse(caniuse.com) or similar sites so that you know which vendor prefixes to use? That might be fun and exciting the first dozen or so times, but eventually it gets a bit old. One nice thing about Sass is that you can just type:

.some-class {
  @include background(linear-gradient(top left, #fff, #eee 50%, #000 100%));
}

into your CSS, and it will automagically spit out:

.some-class {
  background: -webkit-gradient(linear, 0% 0%, 100% 100%, color-stop(0%, #ffffff), color-stop(50%, #eeeeee), color-stop(100%, #000000));
  background: -webkit-linear-gradient(top left, #ffffff, #eeeeee 50%, #000000 100%);
  background: -moz-linear-gradient(top left, #ffffff, #eeeeee 50%, #000000 100%);
  background: -o-linear-gradient(top left, #ffffff, #eeeeee 50%, #000000 100%);
  background: linear-gradient(top left, #ffffff, #eeeeee 50%, #000000 100%);
}

There is a bit more to it than that, as you need to get Compass, which is basically the Sass compiler and then compile your Sass. But it really is a pleasurable workflow once you have it all set up.

Some other things that Sass can do is have variables, so you don't have to jump into Photoshop and grab your logo's color every single time you want to use it in your stylesheet, resulting in tons of different colors being declared throughout the file. Sass also greatly simplifies nesting. For example:

#someId {
  @include transition(all 0.3s ease);
  .someClass {
     .someDeeperClass {
       @include background-clip(rect(0px,50px,200px,0px));
       @include rotate(-25deg);
     }
  }
}

Would result in:

#someId {
  -webkit-transition: all 0.3s ease;
  -moz-transition: all 0.3s ease;
  -o-transition: all 0.3s ease;
  transition: all 0.3s ease;
}
#someId .someClass .someDeeperClass {
  -webkit-background-clip: rect(0px, 50px, 200px, 0px);
  -moz-background-clip: rect(0px, 50px, 200px, 0px);
  background-clip: rect(0px, 50px, 200px, 0px);
  -webkit-transform: rotate(-25deg);
  -moz-transform: rotate(-25deg);
  -ms-transform: rotate(-25deg);
  -o-transform: rotate(-25deg);
  transform: rotate(-25deg);
}

It really is very simple once you have messed around with it for an hour or so, and the code that comes out of it feels refreshingly clean!

If any of this Sass stuff sounds like fun, I suggest checking out the following article by Adam Stacoviak on The Sass Way, and checking out Chris Coyier's Screencast on the topic.

Monday, April 28, 2014

Podcasts

I have been tuning in to a lot of podcasts as of late in order to aggregate a better knowledge about what is going on in the web development and design community. In my travels, I have run across a collections of excellent podcast series. In fact, my two favorites are The Web Ahead hosted by Jen Simmons, The Changelog hosted by Adam Stacoviak, and Up Up Down Down hosted by Allen Pike and Nigel Brooke. They have guests on weekly, and spend about an hour discussing a particular topic in in detail. The Web Ahead and The Changelog focus exclusively on web development, and open-source libraries and projects respectively, while Up Up Down Down focuses on video game trends as well as some other more technical aspects of the industry.

You can check them out on their web sites, or subscribe to them on iTunes in order to receive updates when new episodes come out. They also have individual RSS Feeds which will alert you when there is a new episode. Coincidentally, The Web Ahead and The Changelog are actually hosted on the same site, which is 5by5, They have a ton of other podcasts, but I have not checked the other ones out yet.

These podcasts have a plethora of relevant and interesting information, which I find to be not only entertaining but highly informative. For example, in Episode 67 of The Web Ahead, Jen invited Doug Schepers onto the show to discuss SVG, which I'm sure many of us in the web development/design field have heard of, but not necessarily looked into for one reason or another. After hearing Doug, who has been working with SVG for a decade or more, talk about it so passionately, and in such great detail, I am highly tempted to implement it into one of my personal side-projects in the very near future.

The Changelog is fascinating in it's own right, because although The Web Ahead focuses on free web technologies, the The Changelog sets its sights entirely on the open-source side of things, where users can contribute to the project on GitHub in many cases. Open-Source software of all types has always been an intriguing topic for me, so I find myself tuning into this podcast regularly.

Up Up Down Down is hosted by game developers who are currently working in the industry. They have a guest on, and all debate a topic together. For example, I recently listened to Episode 8, in which they invite Ken Wong, one of the designers of  the new Monument Valley, which is available on the Apple App Store. They discussed and debated the ways in which video games can or can not be considered art, and attempted to define how one thing can be considered art while another is not. Although I am not personally involved in the video game industry, I feel as though the host Allen Pike summed it up perfectly in one of their earlier episodes when he expressed his opinion that even people who do not work on video games can enjoy the show if they have any interest in programming in general.

There are a couple of other excellent podcasts, which I have tuned into for an episode or two and plan on going back to. I feel that one I should mention is CodePen Radio hosted by the founders of Codepen.io, Chris Coyier, Alex Vazquez, and Tim Sabat. I have only listened to one episode from these folks, however, I found it extremely entertaining and am going to download the rest of their episodes to listen to soon.

I would love to hear from anyone who may be reading this to find out what kind of podcasts you listen to. And if you don't listen to podcasts, what sort of content do you subscribe to in order to stay in the loop? For example, weekly shows, screencasts, YouTube channels, etc.

As always, feel free to comment about anything that may be on your mind after having read this. Even if you didn't read a word of this, and you just want to plug your favorite podcast, I would love to hear from you.