Service Worker Precache

Service worker is probably one of the coolest new additions in the sea of cool new additions to the world of Front-End Development. It is however a pretty daunting API to get a hold of when you are starting out with it - fetch, cache, oh boy. The simplest way to get started with integrating service worker is to precache all your static files - aka the JS, CSS and and assets you might have. Now this presents a problem. What about when the assets change does that mean we need to manually maintain this file? That seems like a...

Base Tag in Angular Apps - Resource interpreted as stylesheet but transferred with MIME type text/html

This will be a short and sweet post. I have noticed as its one of my highest rated answers in Stack Overflow I thought I would drop the knowledge into my blog as well. If you have clean happy URLs in you angular app - and really who wouldn’t want that - you are using the $locationProvider. Then yuo have this code snipped in the config section somewhere. $locationProvider.html5Mode({ enabled:true }); But if you are missing the base tag you will get this error. Error: [$location:nobase] $location in HTML5 mode requires a <base> tag to be present! Ok no problem...

Angular .component() Method

Welcome to the future - enter the component method. Ok so I guess this will be logically broken up into a few sections - the component method, new life cycle event, the new component controller - the replacement for the linker function and now yes DOM manipulations in the controller. Oh boy the last one you might be thinking - but that is one of the fundamentals we learn - also a massive mistake people make either through ignorance, laziness or a combination of both. #Component Method First up the component method. I was first introduced to it though this...

Cool CSS stuff - Part 2 - SCSS as JS

For me CSS or SCSS is a ways to a means - we need to style elements. However my pleasure on the front end come mainly from JS and the puzzles we get to solve creatively. So when I started playing around with loops and conditional statements in SCSS, I was super excited to see that SCSS can also be a fun way to solve styling issues with more traditional programming techniques. My problem to start with was creating a carrot/triangle pointing to the right. So I started to search the net and came across this cool post about using...

Cool CSS stuff - Part 1 - Checkmarks

This will be more or less an on going sequence of posts based on cool CSS stuff that I want to share. Also it helps me to remember how this cool stuff was done. I have been working with a CSS magician the last couple weeks, a humble one at that, and I have learned a lot of cool tricks. I want to talk about the way he made checkmarks, which blew me away. First off how you get in the mind set of thinking css can do such a thing, but I guess as with all skills it comes...
pow wow!