One of our primary goals in developing Bluetrain.io is to make web development much faster and easier, without losing any of the flexibility and control that is needed for enterprise websites. As a product architect, I knew that one of the important problems to solve was to allow developers to safely execute server side code. Traditional CMS platforms avoid this issue by exposing APIs in the language the core platform is written in. Since each instance (website) is run separately, there’s no risk of conflict. We required a different solution.
Liquid is a templating language designed to solve the exact problem we were facing. It was developed by the team at Shopify.com, a highly popular SaaS ecommerce platform. Liquid provides a safe and simple way of interacting with select variables and application-specific functions. It also provides standard flow control as well as basic data formatting and manipulation.
With Liquid, we’re able to expose site level variables such as page hierarchy and website settings. We can also provide access to model content and structure. Developers can even write their own plugins which allow content editors to persist data, without having to worry about configuring a database.
Liquid was developed with designers and front end developers in mind. The syntax is simple enough that it can be used by those who only have HTML and CSS experience. It’s also fast on Bluetrain.io, regardless of the quality of the code that’s written. We accomplish this by pre-generating most of the content required to display pages into static files. Even if custom sections of Liquid code aren’t written to be performant, they will still be served quickly and efficiently to the end user.
For a firsthand account of how Liquid can be utilized by senior developers, read this post from Boris Krone at one of our agency partners.
Rick O'Halloran is a Principal Architect at Bluetrain.io