我在 IntelliJ Ultimate 中有一个 Web 项目,我的视图和公共目录使用不同的文件夹(由于使用 Node.js 和 Express):
\n\n\n\xe2\x94\x9c\xe2\x94\x80\xe2\x94\x80 public\n\xe2\x94\x82\xc2\xa0\xc2\xa0 \xe2\x94\x94\xe2\x94\x80\xe2\x94\x80 test.css\n\xe2\x94\x94\xe2\x94\x80\xe2\x94\x80 views\n \xe2\x94\x94\xe2\x94\x80\xe2\x94\x80 index.html\n
我想在我的 index.html 中使用简单路径,如下所示:
\n\n<link rel="stylesheet" href="/test.css"/>
但 IntelliJ 显示错误,因为它在我的 index.html 中找不到 test.css:
\n\n\n\n如何将公共目录映射到public/以便/test.css在内部解析为public/test.css?
| 归档时间: |
|
| 查看次数: |
1754 次 |
| 最近记录: |