我正在尝试使用玉。我正在尝试在获取请求中呈现模板我的代码是
app.get('/promocode/generate-promocode',mw.authenticate,function(req,res)
{ res.render('index1', {});
});
我的 layout.jade 文件代码是
doctype 5
html
head
block head
title= title
include layout/css
include layout/headerjs
body
include header/main
include layout/topbar
.middle-content
.container
.wrapper
block content
include footer/main
include layout/footerjs
我的 index.jade 文件代码是
extends layout
h1 Welcome to Marketplace
h1 Welcome to Marketplace
h1 Welcome to Marketplace
h1 Welcome to Marketplace
h1 Welcome to Marketplace
h1 Welcome to Marketplace
当我转到页面时,它只显示 layout.jade 语法没有 h1 标题,内容为“欢迎来到市场”。任何建议如何在 html 页面中显示此标题标签?