mirror of https://gitlab.com/curben/blog
feat: use meta_generator helper instead of filter
https://github.com/hexojs/hexo/pull/3669
This commit is contained in:
parent
2b4a4b8ca5
commit
63150f5153
|
@ -86,6 +86,8 @@ neat_svg:
|
||||||
deploy:
|
deploy:
|
||||||
type:
|
type:
|
||||||
|
|
||||||
|
meta_generator: false
|
||||||
|
|
||||||
# theme config
|
# theme config
|
||||||
theme_config:
|
theme_config:
|
||||||
# Lang
|
# Lang
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
<head>
|
<head>
|
||||||
<meta charset="utf-8">
|
<meta charset="utf-8">
|
||||||
|
<%- meta_generator() %>
|
||||||
<%
|
<%
|
||||||
let title = page.title
|
let title = page.title
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,7 @@
|
||||||
|
'use strict'
|
||||||
|
|
||||||
|
function metaGeneratorHelper () {
|
||||||
|
return '<meta name="generator" content="Hexo %s">'.replace('%s', this.env.version)
|
||||||
|
}
|
||||||
|
|
||||||
|
hexo.extend.helper.register('meta_generator', metaGeneratorHelper)
|
Loading…
Reference in New Issue