T4 Angular Template Cache

in Angular, T4

There’s a few ways to handle you’re angular directives and they all suck for different reasons.

Store them inline in your directives

The advantage to this method is you don’t have to make a separate web request, and it’s the simplest way to approach templates. This is where I started putting my templates, and I continue to put some templates here if they are very small and more important, simple.

Continue Reading

XPath to Select Node Based on Child Node's Attribute

in XPath

Thankfully I don’t use XPath frequently, but every time I do I end up having to google something. Today was no different except that my googling turned up nothing on my problem.

I needed to select a node based on the attribute of one of it’s child nodes. Simple right?

Continue Reading

Prematurely Optimizing My Blog

in Random

This blog isn’t what you’d call ‘high traffic’. My big problem wasn’t load, it was keeping the site ‘warm’, so each user didn’t have to wait for WordPress to spin up and before serving the first page. Of course once I started looking at performance, I went fully down the rabbit hole and came out on a different blogging platform with a site that was “faster than 100% of all tested websites” according to Pingdom

Static Site optimized on GitHub

Continue Reading

Blog Engines Compared

in Random

I loved WordPress in so many ways. There were hundreds of styles to choose from, a huge library of plugins, analytics, and performance problems. I’m not saying that WordPress can’t be configured to give adequate (or even excellent) performance, but I either didn’t have the knowledge or the money to do so.

So, I went looking for other blog engines, and here’s what I found.

Continue Reading

My First NoSQL Table

in NoSql

I come from a relational database background. Specifically I’ve been using Microsoft SQL for 18 years. At this point data modeling for a relational database is second nature.  Data modeling in NoSQL on the other hand has been somewhat mysterious to me. I’ve read up on some of the strategies for where to break NoSQL data into separate tables, but have had little real world experience.

The lack of real world experience has been two-fold. First I haven’t seen a NoSQL database designed by someone who really knew their NoSQL data modeling, and…

Continue Reading

The Perfect Job

in Random

Occasionally after telling a recruiter that I’m not interested in a position (yes, I try to respond to the ones that are not obviously spam) they’ll ask what I am looking for, which is an odd question since I’m usually not looking.  I usually listed a couple of things, but from this day forward I will refer them to this post.

Continue Reading

Scheduled Jobs in Azure

in Azure

Have a process you need to run periodically on your Azure hosted application? It’s simple to do with Azure Scheduler.

From the Azure Management screen (not currently available in the new portal) click New->App Services->Scheduler->Custom Create

Continue Reading

C#6 String Interpolation

in C#

Another feature I’m looking forward to in C#6 is string interpolation.  We’ve all had to create string messages to show the user that include data from the application, or maybe we’re just writing some debug information to the console.  We can build these messages a few ways right now.

Continue Reading

Why You Should Give a Lightning Talk

in Community

I previously posted that I had appointed myself Community-Booster, and so I now see it as my job to convince you to give a lightning talk at your local user group.  I could start by listing the benefits to you, or to the benefits to the user group, but I don’t think the for most people the fear of things going poorly outweigh the potential benefits.  So let’s focus on your fears.

Continue Reading

Null Conditional Operator

in C#

There are a bunch of cool features coming in C#6, but the one I’m looking forward to the most is the Null Conditional Operator.  Developers write a lot of code to check if a value is null.  Sometimes it creates a deep and ugly nest of if statements.  Let’s say you are trying to find a customer’s primary contact’s city, it might look like this:

Continue Reading