Sunday, October 20, 2013

Facebook should introduce a clothes tagging feature

The next big feature that Facebook should bring out is clothes tagging. This will allow parents to tag clothes that they've given to friends' kids and track how many times they've been passed on. Recipients of clothes can give clothe-tag-thanks to those who gave the clothes as a gift or a hand-me-down.



The data collected from the clothes lineage (assuming you can identify the label) could be used to calculate the hardiness of the clothes and manufacturing quality. The more kids that were able to wear the same t-shirt or shorts will be the ultimate vote in quality. You could also determine which kid treats their clothes the roughest if there's no lineage from them onwards.

This will also help track when friends and siblings don't return clothes they borrowed. Tag that blouse in a photo of you on Facebook and then link-tag it in your your sister's photo. The public humiliation will ensure that she returns it to you.

NodeJS Express Automatic Content Type

Try this in a NodeJS Express application. Add a route as shown below and take a look at what the web page shows:
app.get('/mytest', function(req,res){
    var testdata = {
        segment: 'Five',
        value: '42',
        environment: 'development'
    };
    res.send(testdata);
});
Before you go to this page in your browser, probably something like http://localhost:3000/mytest you should bring up the Developer Tools, on Chrome you can do this by hitting F12 or Ctrl+Shift+i.

In the browser you will see:
{
  "segment": "Five",
  "value": "42",
  "environment": "development"
}
In the Developer Tools take a look at the Response Headers in the Headers section. You will see that Content-Type is set to application/json; charset=utf-8

Now let's change the mytest function to the following:
app.get('/mytest', function(req,res){
    res.send('this is my data');
});
The browser will now show you:

this is my data

If you look at the developer tools you'll see that the Content-Type is now text/html; charset=utf-8

NodeJS/Express detected the type of data that you're sending back to the browsers and adjusted the Content-Type appropriately.

Saturday, October 5, 2013

Audit Controls or People

In my senior year at college I took Auditing along with a number of other accounting majors. I was on track to become an accountant, and in fact became an accountant, until I mainlined some source code and was unable to turn back.



The only thing that I really remember from that auditing class was our professor telling us about controls and people. His comment was: "You can put in as many controls as you want to enforce or prevent something from happening and someone will always find a way around them. At the end of the day you need to hire the right people who don't need those controls in place."

When I heard this it made absolute sense and have always sought to surround myself with the right people and by default trust everyone. There have been occasions when I've been let down which is what you'd expect with a large enough sample size. As I mature and become better at accessing people the disappointments have dropped.

This ties in nicely with the Agile Manifesto and the autonomy that you give to teams to self form and determine what they can get done in a sprint. If you have the right developers on the team the controls can be minimal or none. Trust is the key. Awesome results are the end products.

Wednesday, October 2, 2013

A Dozen JavaScript Libraries

Just spent a couple of hours this evening listening to Rob Richardson give an awesome presentation on A Dozen JavaScript Libraries.

He covered:
  1. jQuery
  2. Lo-Dash
  3. Handlebars
  4. Modernizr
  5. Moment
  6. Normalize.css
  7. Twitter Bootstrap
  8. jQuery UI
  9. Backbone
  10. Angular
  11. JSHint
  12. Jasmine
  13. RequireJS
  14. Rafael
in enough detail to arm you with the ability to select one of them for a future project. It also looks like he's extended the Baker's Dozen (13) metaphor to a JavaScript Dozen (14). I'm guessing that JavaScript has the math library to do that.

Also love that he's using reveal.js for his presentations.

Good work Rob!