Skip to main content

Posts

Showing posts from February, 2013

Reading Update

From my last post: http://krzychukula.blogspot.com/2013/02/reading-list-update.html

Finished:

SMACSS by Jonathan SnookCzytaj dwa razy szybciej! by Marcin Matuszewski (how to read faster)JavaScript Allongé by Reginald BraithwaiteThe Programmers Stone readlist from blog: the-programmers-stone.com
Now I'm reading:

Hexagonal Architecture for SCKRK MeetingFallen Dragon by Peter F. Hamilton (sci-fi) Next on my list: Effective JS by David HermanMake: Electronics. Learning Through Discovery By Charles Platt (I will finish first chapter in february)

SMACSS Really good book about CSS, architecture of CSS in small to really big projects/websites. How to deal with duplication - especially how to avoid it. There is even a chapter about Preprocessors and I can strongly agree that this is tool that can help you but only if you are conscious about how it works and how CSS it generates looks like.

JavaScript Allongé Book that explains Functional programming with JavaScript. I found many functional a…

Recommendations to STP

I realized that this blog could actually help me earn some money so beware this is non technical post ;)

At STP (Schibsted Tech Polska) we have recommendation bonus and I can earn some money by recommending someone (sending his CV).

If you're thinking about new job, or are just curious how our office look like just send me your CV :)

Most of the time we're searching for JS, PHP or Java Devs. Office is in Krakow, we work closely with Norway/Sweden companies of Schibsted. Let me know if you have questions.

We look for people that want to do:

Scrum MasteringProgramming JavaLearning Programming in Java (Junior ;)FrontEnd (JS/CSS etc.)

Send CV to krzychukula [ at ] gmail.com

Image from: http://2bgr8stock.deviantart.com/art/Money-Cash-113445826

Sitespeed.io - Performance reports of your site

Today Andrzej Maciurzyński @ajumac send me link to really nice tool to check good practices of websites from your backend. Testing within browser is great but you can't easily share result within a team or make it part of build or continuous integration process.

With http://sitespeed.io/ using Phantom.js you can generate performance results of your page and publish it next to your site. This can be really useful to see if your last commit make something slower.



Reading list update

Time for update of my reading list from December: http://krzychukula.blogspot.com/2012/12/reading-list-update-december-2012.html


Professional HTML5 Mobile Game Development by Pascal RettigMake: Electronics. Learning Through Discovery By Charles PlattPrzemów do nich! Teoria i praktyka wystapień publicznych by Jarosław Kordziński - this one is about public speaking and is really short.Unity Game Development Essentials by Will GoldstoneMaintanable JSEffective JSSMACSS
Most of it still waits but in the meantime I have read some others:
Cooking for Geeks: Real Science, Great Hacks, and Good Food by Jeff PotterPretty good, I'm still afraid to cook but now I try to do something more often, and because of what I learned sometime it can be eaten ;)Przemów do nich! Teoria i praktyka wystapień publicznych by Jarosław Kordziński - this one is about public speaking and is really short.Short and too abstract for me, but quotes at the end are fun.Professional HTML5 Mobile Game Development by Pasca…

Udacity HTML5 Game Development Classes Just Started!

Classes just started so if you're into HTML5 Game Development this can be really beneficial to have some real classes and schedule for learning about it :)

https://www.udacity.com/course/cs255

For the ones new to HTML/JS there is a JS crash course as first optional lesson so this should be enough to get you more familiar with technology.

I don't know much about content of this course besides that we're going to build GRITS game as shown at last Google IO:





Image from udacity.com

Promises in Code

To see more general explanations of promises: Promises and Deferreds - How I Stared To Like Them

At a basic level what Promises do is the same thing as passing a callback to a function.

function myFunc(callback){...} myFunc(alert);var promise = myFunc(); promise.then(alert);
But it is easy to get too many callbacks (if you work without promises), you need at least two, one for error and one for success. Functions need some arguments and you end up with a monster like:

myUgly(success, error, param1, param2, param3)
or move to a config object:

myBetter({success: success, error: error});

When I want to add another success function it gets uglier:

myBetter({successes:[success1, success2], error: error});

The same functionality with promises will be probably more verbose but I think this is a good thing. The code below is much more maintainable and extensible:

var promise = myPrecious({param1, param2, param3}); promise.when(success1); promise.when(success2); promise.when(success3); promise.fa…