无效的缩进,您可以使用制表符或空格,但不是两个玉
我有以下的玉代码工作正常
div.container h3.entry-title(style='margin-top:25px;') #{result.post_title} div p.text-left.pst <i class="fa fa-calendar"></i> #{result.post_date} div.panel !{result.post_content} -if(typeof userType !== 'undefined' && userType=='admin') a.btn.red.marginTop(href='/ebs' ) Cancel div.page-footer div.page-footer-inner Copyright Copyright All rights reserved.
但是当我尝试插入像下面的语句,它给我的缩进错误
div.container h3.entry-title(style='margin-top:25px;') #{result.post_title} div -if(result.post_date!='-1') p.text-left.pst <i class="fa fa-calendar"></i> #{result.post_date} div.panel !{result.post_content} -if(typeof userType !== 'undefined' && userType=='admin') a.btn.red.marginTop(href='/ebs' ) Cancel div.page-footer div.page-footer-inner Copyright Copyright All rights reserved.
在编辑器中查找选项以突出显示标签或空格。 或者只是删除所有的缩进,并重新添加它只使用标签或只有空格仔细。
Pug(formerly Jade)
模板工作在相同的缩影。您需要在
pug
文件中selectspace or tab
。 你不能同时使用两个。
从编辑器中select常见缩进,并从这个奇怪的错误