0

I want a shopify like functionality in my app which I am developing. Shopify template engine support this syntax in theme files.

<ul id="blogs">
  {% for article in blogs.frontpage.articles limit: 3 %}
  <li><a href="{{ article.url }}">{{ article.title }}</a></li>
  {% endfor %}
</ul>

I also want this type of functionality for mine.

Cœur
  • 37,241
  • 25
  • 195
  • 267
Shakeeb Ahmed
  • 1,778
  • 1
  • 21
  • 37

2 Answers2

1

Sounds like you need a templating engine for your app. You could use an off the shelf one such as the ones recommnded here.

Community
  • 1
  • 1
mopoke
  • 10,555
  • 1
  • 31
  • 31
0

Your example code looks exactly like a Django template: if that's precisely what you want, you can use Django templates in .NET with IronPython (if you don't care about the kind of template language in use, @mopoke's answer gives a URL listing many others).

Alex Martelli
  • 854,459
  • 170
  • 1,222
  • 1,395