monreestudio / monreestudio.github.io Goto Github PK
View Code? Open in Web Editor NEW个人主页
个人主页
@MonreeStudio 要在特定的页面隐藏 Header,可以考虑魔改一下布局文件,当 page.layout
含有 no-header
子串时跳过 Header 的加载。
themes/edinburgh/layout/layout.ejs
diff --git a/layout/layout.ejs b/layout/layout.ejs
index 5a69488..4cd9a80 100644
--- a/layout/layout.ejs
+++ b/layout/layout.ejs
@@ -5,8 +5,11 @@
<body>
<div class="container-fluid navbar-container m-sm-5">
- <!-- Header -->
- <%- partial('_partial/header') %>
+ <% // Skip header if page.layout contains '-no-header' substring %>
+ <% if (!(page.layout && page.layout.includes("-no-header"))) { %>
+ <!-- Header -->
+ <%- partial('_partial/header') %>
+ <% } %>
<div class="row">
<%- body %>
下面是一个测试用的页面:
---
title: Summer
date: 2020-08-09 22:05:58
layout: page-no-header
---
## 夏天
天青色等烟雨,而我在等你。
月色被打捞起,晕开了结局。
效果如下:
“夏日“介绍页面的流畅设计体系的那个链接已经被巨硬吃掉了哦。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.