sirlantis/liquid-node — pull request #3 by tchype (2012-01-01 01:01:36+00:00)
Title: Some tweaks to allow client-side to work?

Hey again!

I made some changes to the structure of the requires to remove circular references (e.g., Liquid refers to Liquid.Block, which refers to Liquid). I introduced a "liquid_base" file that is the initial definitions of the Liquid class that both the final Liquid module and the block, tags, etc. refers to.

I also moved the work to load tags into a function and wrapped a try/catch around it since there is no fs module on the client-side.

By doing this, using browserify actually works! I generated a **liquify.js** that you can find in https://github.com/tchype/node-liquify in the public/javascripts folder.

By running the app.js with node and opening http://localhost:8125 in your browser, you can see liquid working a little bit, fully client-side!

Hopefully this isn't too ugly, because it's a **HUGE HELP** and made all the difference in getting it to work client-side.

Thanks again! Nice work, man. It only took me like 1-2 days total to go from nothing to seeing liquid working in the browser. Remarkable. You did a _great_ job.
Tony