Bacon.js Tutorial

I updated two of my most visited blog posts: Bacon.js Tutorial. Now they use latest version of jquery 1.x and Bacon.js. There has been changes in jquery integration so posts were updated to work also with the new model.Bacon.js

Bacon.js is FRP / Functional Reactive Programming library for JavaScript. Bacon.js solves bizarreness of RX-JS hot and cold Observables.  FRP introduces cleaner way of creating event streams from different sources combining them with means of Functional Programming.

Bacon.js for Functional Reactive Programming

Bacon.js – Bus

Varnish and WordPress, Corner Cases

The Corner StuffWordPress Varnish Corner Case

My previous Varnish and WordPress post, Make WordPress Faster with Varnish Cache, was good introduction how to get your site fast. It still left some cases untouched. In this post I will look into these cases and fix them. Cases include some Varnish and WordPress configurations.

WordPress Caching with W3 Total Cache

This is very popular caching plugin for WordPress. It has lot’s of features that we can take advantage of. Why I’m installing another cache behind  Varnish? Well, they do not rule each other out. Varnish will use it’s cache better if server sends proper browser caching values. By default, WordPress will not take advantage of browser caching. With this, we can reduce requests to server and have proper TTL values for objects in  Varnish Cache.

Go ahead and install W3 Total Cache. It includes loads of features by default so don’t get exhausted. Take your time and browse around what’s where. You can find all the option from left side under Performance Menu.

W3 Total Cache also includes minifying tools so I uninstalled Better WordPress Minify. There’s loads of guides how to tune settings, so I’m not going to do that. Bare minimum you should be enabling is: minifying, page cache and browser cache.

 

Disable Caching for Logged In Users

You don’t want to cache content of your logged in users. Long story short: add this to your policy file.

Disable Caching for Search Results

Repeating my self: Don’t cache search results: add this your policy file.

Normalize Accept-Encoding Headers

By default, Varnish 4.0 will tamper your requests to add Accept-Encoding header to your requests. There’s still caveat on this. Browsers send Accept-Encoding headers different order and all get their own hash bucket in Varnish Cache. Waste of resources. Also we do not want to compress again compressed object. So, go ahead and add this your policy:

Graceful Content Refresh

If you use default configurations for refreshing of objects, you might get small delay when refreshing content from back end. This is why we must allow Varnish to fetch content asynchronously and replace object gracefully.

This is how it’s configured.

Health Check

One of the core features of Varnish Cache is to shield from misbehaving back end servers. Here’s basic configuration to enable health check.

Varnish and WordPress, Corner cases

In this post I’ve shown some cases that makes your web site even more stable and fast. Again you can find sources from Github.

Getting Started with Windows Phone 8 Development

Developers, Developers, Developers

Can I Have Some Links, Please.

Can I Have Some Links, Please

So, you got tools to getting started with Windows Phone 8 Development, but don’t know how to do it? How do I design my UI?  In this post I will try to answer to these questions. If you don’t know where to get tools, visit my previous Windows Phone 8 Development, Dark Side.

First Tutorial

I’m not going to  copy paste tutorials from Microsoft website here. Instead go a head visit Microsoft Development Site and make tutorial from there. Of course after you’ve read this blog post.

There’s two possible options to start:

There’s loads of resources loaded behind these two links, read them thoroughly.

Yes, you can do Windows Phone 8 Development with JavaScript. Though I’ve done WinaBlip, a Blipfoto application for Windows Phone 8, with C#. Reason is purely educational – I wanted to learn C#.

 

Port an Existing App

Surprise,  surprise, Microsoft have made tutorials and comparisons how to port your existing iOS or Android application to Windows Phone 8. Here’ s small introductory video:

Resources for porting  applications are not only Windows Phone 8 specific, but universal to whole Windows Runtime Platform. So, here’s the link to main website of porting applications:

 

Design Principles

There are some UI design principles than should be fallowed. They differ from iOS and Android and requires little a bit investigating. Some of the basic principles of UI design to Windows Phone 8 to get you started:

  • Don’t create buttons just for buttons, use UI elements as buttons.
  • Make your UI for Portrait and Landscape
  • Make your UI scale to different screen resolutions
  • Try to use UI with your thumb, if you can’t – redesign

Whole bunch of guides how to design your application properly can be found behind this link:

Take a look before you start making your million dollar app.

API

Every developer needs API description. Well, here it is, all-in-one:

 

Forum

We need forums, support from other developers. Here’s forum just for Windows Phone 8 Development:

 

Blog

If you want to fallow tips and tricks from Microsoft, subscribe to their blog:

 

Summary

Getting proper resources can be a bit tricky sometimes. Microsoft is trying to embed Windows Desktop, Phone and RT development which is causing some resources to be hidden inside Microsoft webpages. Luckily there’s somewhat active development community so you can always use google if you can’t find answer from Microsoft pages.

Here’s all links in one:

Python Tutorial

Here’s all of my Python tutorial in a one Post. There’s still some chapters to be written so I will add them also here when published.Python

Python is interpreted, high-level and very readable programming language. It supports object-oriented, functional and imperative programming. It does not include curly brackets to indicate scope. Python uses indentation to separate code blocks. Language rejects Perl philosophy: “there is more than one way to do it” in favour of  “there should be one—and preferably only one—obvious way to do it”.

Python Tutorial – Basics

Python Tutorial – Dictionaries

Python Tutorial – Lists

Python Tutorial – List Comprehensions