Posts

Showing posts from January, 2015

[Javascript] - Grunt by Example - A Tutorial for JavaScript's Task Runner

What’s Grunt used for? Automating front-end and JavaScript workflow tasks. Refreshing the browser when you change a script. Minifying and concatenating. Running tests. Think   rake   and   guard , if you’re coming from the Ruby world. Enter Grunt by Example! A blow-by-blow tutorial. Just the way I like it. Let’s dive in. The catch - Grunt configuration files can be fairly convoluted at first glance, usually due to the fact that developers add more and more steps to their workflow over time. Grunt is just a task runner. Every unit of functionality that you would want is usually achieved with a separate npm package (a grunt “plugin”). npm search grunt  to view literally every grunt plugin available. Get the command line interface:  npm install -g grunt-cli Add the actual grunt task runner as a development dependency to your project ( --save-dev  adds the package as a dependency to  package.json ): npm install --save-dev grunt Let’s fol...

[Office - Productive] 14 Things Successful People Do In The First Hour Of The Workday

Image
Successful people greet their colleagues each morning. The first hour of the workday is critical, since it can affect your productivity level and mindset for the rest of the day. "Successful people understand the importance of having control over their mornings and know how to use that time wisely," says Lynn Taylor, a national workplace expert and the author of "Tame Your Terrible Office Tyrant: How to Manage Childish Boss Behavior and Thrive in Your Job." "These people are able to weed out the noise in their first hour and focus on what matters." Everyone has their unique method of prioritizing, she says. "But all successful people stay focused when they start their day, and with years of practice, they realize that many things can wait, and others cannot." Here are 14 things successful people do in the first hour of the workday: They step back and reflect. Taylor says it...

[Mac OS] - Show/Hide Hidden Files the Long Way in Finder

Image
Show/Hide Hidden Files the Long Way The long way to show hidden Mac OS X files is as follows: Open Terminal found in Finder > Applications > Utilities In Terminal, paste the following: defaults write com.apple.finder AppleShowAllFiles YES Press return Hold ‘alt’ on your keyboard, then right click on the Finder icon in the dock and click Relaunch. Relaunch Finder by right clicking the Finder Icon whilst hosting the 'alt' key. This will show all hidden files  To hide them again, follow the same steps but replace the Terminal command with: defaults write com . apple . finder AppleShowAllFiles NO It’s not the longest set of instructions or the biggest command to commit to memory but if you’re doing this a lot, it’s worth spending a few minutes now to save yourself a lot more time in the future.

[HTML5] - The !DOCTYPE Tag and Its Effect on Page Rendering

 I never gave much thought to the DOCTYPE tag because my HTML editor always included it in the page template. It wasn't until the arrival of HTML5 that I noticed how much it had changed since version 4. Around the same time, I also noticed that my browser - Internet Explorer 9 (there I said it!) - was switching to "quirks mode" when loading certain pages. Then, a little later, I put two and two together and came to understand that the two were related. In today's article, we'll see how as we learn about the DOCTYPE tag and it's effect on page rendering. What Is the DOCTYPE? The DOCTYPE declaration, which should be the first tag in the source markup of any web page, is utilized by the web browser to identify the version of the markup language in which the page is written. It may contain a link to a Document Type Definition, or DTD for short. The DTD sets out the rules and grammar for that flavor of markup, thus enabling the browser to render the cont...