Articles

Moving from HTML Grid Systems to CSS Grid Systems

I think it was a few months ago where someone asked me if I had any pointers to help them transit from Bootstrap’s dom-littering .col classes to either Susy or Neat. It struck me that I haven’t talked about this even though I’ve been using Susy grids for so long!

Anyway, this transition is a fairly big undertaking if you’re doing it for the first time. Allow me to walk you through a four-step process that I use in this article.

Read more

Is Web Typography Completely Broken?

I recently came across an article titled “Web typography is broken. Here’s how we can fix it”. A mix of emotions rushed through me while I read through it. I realized that the biggest argument Tom was making in the article was that web typography is broken because type doesn’t sit perfectly on a baseline grid.

On one hand, I was happy to see people coming up with ideas to push code to their limits.

On the other hand, I’m unsettled. I asked myself: “Is there a need to make every line of text sit on the baseline“? I knew the importance of Vertical Rhythm and the baseline grid. I also knew that details matter when it comes to design. But is this one detail enough to break web typography?

As I browsed through the internet looking for answers, I found out that even great designers like Mark Boulton remarked that it would be cool if CSS gave us a pain free baseline grid.

This increased my urge to find out if web typography was completely broken. After all, if a great designer said the same thing, then sticking perfectly to the baseline grid should be important. Right?

Read more

PX, EM or REM Media Queries?

Have you wondered if you should use px, em or rem for media queries? I had the same question too, and I never figured it out, not till now.

When I first created the mappy-breakpoint library over a year ago, I used rem units. Then after a conversation with Sam Richard, I quickly switched to em instead because I found out there isn’t a difference between the two.

In addition to em and rem, a popular unit of choice for media queries is the good old pixel. I wondered if it’s possible to use pixel queries nowadays since px-zooming problem that used to exist was now resolved by all browsers.

This week, I finally decided to get to the bottom of this matter.

Read more

Viewport Unit Based Typography

I talked about using rem and em for responsive typography and for building modular components in two blog posts previously. In both posts, comments about viewport based units inevitably comes into the picture.

I resisted working with viewport units for a while, believing that using them would be a pain in the ass because of the calculations involved.

Last week, I finally overcame the resistance and took a stab at exploring viewport units and how to use them in responsive typography.

Read more

Why is Vertical Rhythm an Important Typography Practice?

You probably heard of the term Vertical Rhythm if you researched a little about typography on the web. It’s one of the most important practices when working with typography. I’ve used Vertical Rhythm on all my sites ever since I read about it.

One day, it struck me that I haven’t had a clue why vertical rhythm was important. Two more questions quickly arose following that thought: “How does Vertical Rhythm improve the design of the site? What lessons can I draw from Vertical Rhythm so I can improve my design?”

I decided to find out why. Here are my thoughts.

Read more

REM vs EM – The Great Debate

One of the best practices to typography on the web is to use relative units like rem and em.

The question is, which should you use? There’s been a longstanding debate between rem supporters and em supporters, believing that you should use one over the other.

In this article, you’re going to find my take on rem vs em. You’re also going to learn exactly what rem and em are, and how to use them to build modular components.

Read more

Star Rating Re-imagined with Flexbox

The rating element is one UI pattern that you’ll find everywhere on the web. I found myself building another rating element for the second time in my life a few weeks ago.

Since it’s my second time working on the same element, I wanted to challenge myself to come up with a way that uses as little code as possible. Consequently, I managed to come up with a way to build the rating element with only 50 lines of code (HTML, CSS and JavaScript combined), which is incredibly sweet! This article shows how I did it.

Read more

Building a Simple CRUD Application with Express and MongoDB – Part 2

This article is the second part on creating a CRUD application with Express and MongoDB. We’re going to venture deep into the last two operations that were not covered in the first partUPDATE and DELETE.

Without further ado, let’s start the second part.

Read more

Building a Simple CRUD Application with Express and MongoDB

If you know me you would have known that I started learning about the web without having gone through any computing courses in university previously. I didn’t dare to venture into server-side programming for a long time because of my background.

I remember when I eventually picked up the courage to try, I had such a hard time understanding the documentations for Express, MongDB and Node that I gave up.

One year later, I finally understood how to work with these tools. Then, I decided to write a comprehensive tutorial so you won’t have to go through the same headache I went through.

Read more

Everything I know about Responsive Web Typography

Responsive typography is a tough nut to crack. This was the best method I could come up with when I first started creating responsive websites:

p {
  font-size: 16px;
}

@media (min-width: 800px) {
  p {
    font-size: 18px;
  }
}

/* Repeat for h1 - h6 and other type groups */

I’ve learned a lot more about typography since then and picked up best practices like using relative units, vertical rhythms and meaningful typography scales.

These new practices were wonderful. They made my websites look more pleasing to the eye. Implementing them, however, was a horrible experience.

I had to write complex code and I found myself struggling to create responsive websites under tremendous time pressure.

Now, after months of hacking, I’ve finally created a solution that I’m happy to share with you. It’s called Typi.

Typi is great because it allows me to use the practices I’ve learned, and at the same time solves most of the problems I’ve encountered in 3 simple steps. Let me explain these three steps by walking you through the practices I use when working with responsive typography.

Read more

Year End Review – 2015

2015 has gone by in just a blink of an eye. I realized that I haven’t been taking stock of my life for the past 27 years. So, I decided to do a year-end review for the first time to end 2015 completely, and the begin 2016 anew.

Read more

Animating SVGs (CSSConf.Asia talk)

I gave a talk about animating SVGs in CSSConf.Asia 2015. The video is finally ready and I’m super stoked to share it with you! Have a look and let me know what you think! :)

Read more

Trolls & Expert Opinions – Lessons Learned From Publishing on a Popular Website

I recently published an article on Smashing Magazine. For those who don’t know, Smashing Magazine is a well respected website in the design and development world. It’s kind of like Lifehacker or Tiny Buddha, but for web designers and developers.

I was incredibly proud of the article I published. It took weeks of effort and I was elated that I made a contribution to the world. I went to sleep feeling awesome about it.

Unfortunately, I woke up feeling horrified when I looked at my twitter notifications the next day. Many people (mostly whom I don’t know) commented on my article, saying how “the author doesn’t know what he’s talking about”, that “it was a bad article”.

Even people whom I know and respect said that they felt “confused and bizzare” that an article like mine appeared on a well-curated website like Smashing Magazine, and they were “getting worried” about the contents of the article.

The same happened under the comments section on Smashing Magazine as well.

What a great start to the day. What would you have felt, or did?

Read more

Overcoming Your Fears

“Thanks for helping to organize Devfest.Asia!” Someone said to me as the largest community-organized web developer festival in South-east Asia draws to a close. “I really enjoyed it!”.

I should be happy when I hear things like this. Right? Well, I thought so too. But I didn’t feel it.

Deep down inside, instead of happiness, I feel a stab of pain whenever someone thanked me for organizing Devfest.Asia.

Strange, isn’t it? I couldn’t explain this feeling for a long time.

Now, I finally understood what has happened, and how it affects my life. I’d like to share this story since it might affect yours positively too.

Note: This would be an interesting read if you are someone who constantly feels you’re not good enough, or you haven’t done enough. For the rest, you can stop reading here now.

Read more

Migrating From Bootstrap to Susy

One of the most asked questions I get about migrating from Bootstrap to Susy is this: “How do I build a Bootstrap-like grid with Susy?”

I feel that if I answer this question, I’ll be leading you down a path that I don’t agree with. That’s why I hesitated with answering this question previously.

In this article, I want to tell show you why this is a wrong question to ask, and what to do instead.

Read more

What to add to your Gitignore File

What files should you push up into a Git repository? What files should you ignore? These are two questions that plague most beginners when they’re learning about Git.

We’re going to explore these two questions in this article so you’ll never have doubts on whether you should ignore a file in the future.

Read more

How to Modularize HTML Using Template Engines and Gulp

Template Engines are tools that help us break HTML code into smaller pieces that we can reuse across multiple HTML files. They also give you the power to feed data into variables that help you simplify your code.

You can only use template engines if you had a way to compile them into HTML. This means that you can only use them if you’re working with a backend language, or if you’re using client-side JavaScript.

However, with Node.js, we can now harness the power of template engines easily through the use of tools like Gulp.

That’s what we’re going to cover today in this chapter. We’re going to find out what template engines are, why we should use them, and how to set one up with Gulp.

Read more

A Gulp.js Tutorial (Part 2)

Last week, we set up a simple gulp task to convert Sass into CSS. We also touched on how to watch the styles.scss file for changes and how to reload the browser automatically with Browser Sync.

In this article, we’re going to dive further into the sass task to find out how to watch more than one file for changes, and how to customize options for the plugins that we have used.

Let’s get started.

Read more

A Gulp.js Tutorial

Gulp is a build tool that helps you automate your development workflow. In this article, we will dive deep into Gulp to show you how to use it effectively to create a simple workflow.

Let’s get started.

Read more

Choosing a Build Tool

Choosing to use one tool over another is one of the largest challenges developers face. Regardless of what you’re choosing, be it a code editor, a framework, or even a build tool. It’s never an easy decision.

When it comes to build tools, the two most popular options right now are Grunt and Gulp. But are these the only two you should choose from? If not, what other choices do you have?

Let’s answer this question.

Read more

Hold on while i sign you up…

🤗
Woohoo! You’re in!
Now, hold on while I redirect you.