我正在使用node.js和jade摆弄twitter引导程序,但是我没有加载这个样式表,因为即使目录是正确的,也找不到MIME类型和文件,我推测我需要“设置”路线在服务器端首先像下面的python的bottle框架代码
对于python的瓶子框架
@route('/static/js/<filename>')
def js_static(filename):
return static_file(filename, root='./static/js')
@route('/static/img/<filename>')
def img_static(filename):
return static_file(filename, root='./static/img')
@route('/static/css/<filename>')
def img_static(filename):
return static_file(filename, root='./static/css')
是否有 node.js 等价物?或者,我的翡翠设置是否正确?
任何提示将不胜感激
玉文件
!!! 5
html(lang='en')
head
title title
link(rel='stylesheet', href='/static/css/bootstrap.css', type='text/css')
body
p The open items are as follows:
table.table.table-striped
tr
td "a"
td "a1"
tr
td "b"
td "b1"
script(src='/static/js/jquery-2.0.3.min.js')
script(src='/static/js/bootstrap.js')
bootstrap.js 在目录中
/static/js/