3
我正在尝试使用Jade
模块,并且我的内容未显示。这里是我的index.jade
:Jade模块如何工作 - Jade
//index.jade
extends ../includes/layout
block main-content
section.content
div(ng-view)
它添加layout
文件中像我期望的那样。下面是该文件:
//layout.jade
doctype html
html
head
link(href="/favicon.ico", rel="shortcut icon",type="image/x-icon")
link(rel="stylesheet", href="/css/bootstrap.css")
link(rel="stylesheet", href="/vendor/toastr/toastr.css")
link(rel="stylesheet", href="/css/site.css")
body(ng-app="app")
h1 Hello Worldd
include scripts
但它不包括我main.jade
:
// main.jade
h1 This is a Partial
h2 {{ myVar }}
或之后的任何代码。这是我第一次使用Jade
,所以我很挣扎。另外,当您包括block
时,-content
是什么?谢谢。