Why Use Liquid?

I can remember that one of the first customers I ever worked with had an office based in Michigan, even though it was an international company with offices all over the world. Our company would ship items to their employees all the time, but for some reason anything shipped to this office needed to send a different email.

This was the early days of the company, and the first time we were trying to accommodate such an unusual request. Since it was the early days, we would do anything for their business and failure was not an option. Without knowing any better, we simply added an "is_in_michigan" boolean database column to our Order model.

As you can imagine, logic began to spread through our application. Everywhere, you would see "if order.is_in_michigan?". I remember, a mentor of mine used to always say, "Whenever you make a decision, think about what would happen if you make that decision 1,000 times.". What they meant by that was, imagine that we got 1,000 customers that all had a special rule and we solved that problem for all 1,000 of them by adding another boolean. As you can imagine, that would quickly become an unmaintainable nightmare!

When your application deals with many different customers, separating the data and the business logic is extremely important to scaling. With the tools mentioned here, Custom Fields, Conditions, Rules and Email Templates, it becomes possible, and even easy, to solve these problems. Liquid becomes the glue that holds all of these pieces together and allows each subsystem to communicate.

Separation of Concerns

Your business should work like Shopify.

Shopify understood that it was not scalable for their engineering team to create a new theme every time they got a new customer that wanted one. Their software engineers would be working themselves to death to build out new themes, which would not allow them to be developing new features and pushing their business forward.

Today, there are hundreds of Shopify Experts and companies that know how to use their theme builder tools. If you’re a new company to Shopify and want a custom theme, that theme can be built by someone and Shopify never even has to know about it!

Valve software is another company that understands this concept. Valve has a team of designers who make hats for their video game Team Fortress 2. They have also released software so that freelance designers can make hats and sell them to people in the game. I once heard Gabe Newell, Co-Founder of Valve, say that their company works hard… but they will never be more productive than their community of content creators.

Even though you may not have a large community of freelance designers or developers, your company can still follow this lead. Your company should have two teams that work together: An engineering team and a configuration team.

The engineering team should be focused on creating the building blocks of your application. The engineers are responsible when a customer requests changes that are not possible with the current toolset. The engineering team is also responsible when things go wrong and there are bugs. You don’t want to have your engineering team building customer specific requests when possible.

The configuration team works using the tools within the application that the software team has built. They configure the application to provide the experience the customer wants. They can gather requirements from customers and build completely independently from the engineers.

Why is this important for your business? One word: money. Software engineers are expensive. Doing this configuration work still takes skill and training, but the learning curve is way steeper to become a software engineer than to learn how to use these configuration tools. The ultimate dream of companies is to achieve what Shopify has. That is, when your users become experts themselves and you don’t need to pay people at all to configure your software.

Lots of companies in the world rely on this kind of separation of responsibility. With this team-architecture, Liquid is the glue that holds everything together and provides a common language. Liquid provides access to the data in a safe and flexible way so that the development team and configuration team can work together seamlessly.