5

I need to give end-users the ability to securely edit an asp.net mvc web application templates and so far Liquid Template Language seems to be perfect, but it is written in Ruby and porting it seems a too complex task for me as I don't know Ruby... anyone tried to port it to C#? It would be really useful in a lot of situations and I'm going to actively help for what is needed!

Update: I also found out a Javascript version, this should ease the porting enough.

Larry K
  • 47,808
  • 15
  • 87
  • 140
MJ1686
  • 51
  • 4
  • Yes this would be a nice library to have in C#. There is the new Razor view engine - but that allows any C# method to be called which is obviously not safe to run on your web server! – superlogical Aug 03 '10 at 20:51
  • Maybe you could use IronRuby and see if you can get it working that way – superlogical Aug 03 '10 at 21:10

1 Answers1

14

Do you mean DotLiquid? It's a .NET 4.0 port of the Liquid template language for Ruby. The template syntax itself is the same as Liquid, but the .NET code takes advantage of .NET / C# conventions as much as possible. It's obviously open source, same as the original Liquid project.

Disclosure: I wrote DotLiquid (well, I did the C# port from Ruby, anyway). Like the original poster, I also wanted to have access to Liquid template syntax from .NET code. I'm hoping it's useful for other people. Liquid's Ruby source code is very clean, and included a full suite of unit tests, so it made porting quite straightforward. If you do find any bugs, please

Tim Jones
  • 1,766
  • 12
  • 17
  • Tim, that is exactly what I was looking for!!! Can you get in contact with me via email? mine is mj186@mclink.it – MJ1686 Aug 20 '10 at 14:52
  • I tried sending you an email but it failed with "550 550 #5.1.0 Address rejected. (state 14)". My email is tim at roasted-amoeba dot com, without the hyphen. – Tim Jones Aug 20 '10 at 16:07
  • Awesome, thanks for posting the link to the project. Looking forward to checking out the code and contributing if needed – Jim Geurts Aug 20 '10 at 18:53
  • I sent you an email to that address, and also a message on github. – MJ1686 Aug 21 '10 at 08:52
  • ops... I just noticed that my email was mispelled, the right one is mj1686 at mclink dot it – MJ1686 Aug 21 '10 at 08:54