Loop in Jade(目前称为“Pug")模板引擎 [英] Loop in Jade (currently known as "Pug") template engine
本文介绍了Loop in Jade(目前称为“Pug")模板引擎的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想使用像 for(int i=0; i<10; i++){}
这样的简单循环.
I want to use a simple loop like for(int i=0; i<10; i++){}
.
我如何在 Jade 引擎中使用它?我正在使用 Node.js 并使用 expressjs 框架.
How do I use it in the Jade engine? I'm working with Node.js and use the expressjs framework.
推荐答案
例如:
- for (var i = 0; i < 10; ++i) {
li= array[i]
- }
详细文档可以查看https://github.com/visionmedia/jade.
这篇关于Loop in Jade(目前称为“Pug")模板引擎的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文