‘Property Declarations’ can only be used in a .ts file (Visual Studio Code)

Visual Studio Code is fast lightweight code editor, but there’s one problem that totally bugs me.

This generates a bunch of malformed errors in syntax detection in the image shown below. If you are facing this issue in Visual Studio Code (v1.5.2), it is because of TS1.8.1. Here’s how to solve it: Install typescript into your project workspace

Read more →


Integrating Golang.org/x/net/context with Negroni

Update: It looks like net/context will now be attached to net/http.Request in Go1.7_early. So, its probably better to stick to negroni + gorilla for development. And wait for Go1.7 to be released. For those who are interested, have a look at: https://github.com/golang/go/issues/14660 https://go-review.googlesource.com/#/c21496   Original post as follows: Golang feels pretty neat and recently I’ve been trying to learn more by developing… Read more →


How to install GoLang 1.5 on Ubuntu

Check what the latest version are from GoLang: Golang Downloads Download and install (update the version to the latest):

Add /usr/local/lib/go/bin to the PATH environment variable. You can do this by adding this line to your /etc/.profile (for a system-wide installation) or $HOME/.profile:

To remove an older version of Golang:

Read more →

How to install GoLang IDEA Plugin for IntelliJ 14.1.x

So, I decided get started with Golang, and the first thing I really needed was an IDE to work with. Luckily, thanks to the awesome efforts of Mihai Toader, Sergey, Alex and many others from the GO community, there already is a neat open-source plugin for Golang on the IntelliJ platform. It actually simple to install, but not exactly straightforward… Read more →

SWIFT: Human Readable Object Ids (oMg-fu-aPL)

The XCODE interface builder is pretty good. But one thing really bugs me. The object ids are not human readable! Small projects are fine, but once you have to start merging, perform diffs and so on, it really becomes an eye sore. Here’s small tool I made today to get rid of the oMg-fu-aPL Download this jar: readoi.jar Copy the… Read more →

SWIFT: Implicitly Wrapped Optionals

Just a quick explanation of how an implicitly wrapped optional can be used. Logically, I would think optional variables are probably more computationally expensive than a normal variable (IMO because it is a fatter object, did not research). So, as far as it goes, it would be best to declare a normal variable in cases where it can not be… Read more →

Github Commands

Just keeping track of frequently used git commands:

Read more →

Android: Singleton vs ApplicationContext

Well here’s a topic that’s hotly debated in Android design. Technically, both of them could work for rapid development. However, I prefer Method B as you can modularize your singletons to support specific functions in each class definition. Best if you can work without them, but its often not the case. Method A – Extending Application Context Step 1: Create… Read more →

SOLN – 403 Forbidden on alias directory with Apache

Here’s to add an alias directory for Apache 2.4 in Windows. Remember to restart your Apache service. NOTE: If it doesn’t work plain-vanilla for you, try using a folder outside of C:\Users\username\.

Read more →