当前位置: 首页 > news >正文

宁波自助建站系统不干净的网站做性

宁波自助建站系统,不干净的网站做性,网站导航是什么,网站膜拜销售003 - Hugo, 创建文章创建文章单个md文件md文件图片总结 文章内容Front Matter文章目录数学公式的显示KaTeXMathJax 图片 003 - Hugo, 创建文章 创建文章 单个md文件 创建文章的方式#xff1a; 手动创建#xff1a;在post目录下#xff0c;手动创建md文件。命令创建图片总结 文章内容Front Matter文章目录数学公式的显示KaTeXMathJax 图片 003 - Hugo, 创建文章 创建文章 单个md文件 创建文章的方式 手动创建在post目录下手动创建md文件。命令创建hugo new post/*.md 单个md文件的创建md文件的命名是随意的web上显示的与文章的title属性有关而与文件名无关。 md文件图片 创建文章的方式 手动创建在post目录下手动创建一个文件夹在文件夹里创建md文件并将需要的图片资源放入其中。命令创建hugo new post/foldername/*.md会自动创建文件夹和md文件。 md文件图片的组合文件夹的名称是随意命名的但文件夹里md文件的命名必须为index.md或index.zh-cn.md否则图片资源可能在打包上传时会消失。 总结 萝卜青菜各有所爱但命令创建有一个优点就是可以在archetypes\default.md里设置创建出来md文件的Front Matter从而不用每次都重复写。 文章内容 Front Matter 可以理解为文章的属性Markdown语法为 --- # 文章标题 title: 0x03 Hugo创建文章详解 # 文章副标题 文章的描述 description: 本文记录创建文章的规范和一些细节。 # 文章的部分url https://jacket-mouse.github.io/p/Hugo-article slug: Hugo-article # 创建日期 date: 2024-01-23 # 文章分类 categories:- Blog # 文章标签 tags [emoji,happy new year ] # 文章封面图 image *.jpg # 如果md里有latex公式语法需要设为true math: true ---文章目录 根据stack主题目录是从二级标题开始的。即一级标题和二级标题同级从三级标题开始依次降级直到四级。所以在书写标题时为了目录的规整从二级标题开始书写一级和五级及以上标题不太用。 另外 记录之前用了一次五级标题导致目录的高光跟随不见了。 数学公式的显示 Mathematical notation in a Hugo project can be enabled by using third party JavaScript libraries. KaTeX 创建Hugo时默认给的是KaTeX来渲染数学公式正如其官网所介绍的一样KaTeX的速度比MathJax快有个比较它们之间速度的网站但是根据我的第一篇数学笔记的效果来看KaTeX有很多LaTeX语法并不能正确的渲染 \displaylines{}begin{cases}可能还有其他的但我并没有一一尝试也有可能是我配置没弄好那样属实有点尴尬 Note: Use the online reference of Supported TeX Functions 官方操作步骤 To enable KaTex globally set the parameter math to true in a project’s configuration 首先要把config.yaml文件里article的math设为true article:math: truetoc: truereadingTime: truelicense:enabled: truedefault: Licensed under CC BY-NC-SA 4.0To enable KaTex on a per page basis include the parameter math: true in content files 然后在写需要显示数学公式的文章时文章属性的math也要设为true Create a partial under /layouts/partials/math.html Within this partial reference the Auto-render Extension or host these scripts locally. !--内容来自Auto-render Extension-- linkrelstylesheethrefhttps://cdn.jsdelivr.net/npm/katex0.16.9/dist/katex.min.cssintegritysha384-n8MVd4RsNIU0tAv4ct0nTaAbDJwPJzDEaqSD1odIWdtXRGWt2kTvGFasHpSy3SVcrossoriginanonymous / scriptdefersrchttps://cdn.jsdelivr.net/npm/katex0.16.9/dist/katex.min.jsintegritysha384-XjKyOOlGwcjNTAIQHIpgOno0Hl1YQqzUOEleOLALmuqehneUGvnGctmUb0ZY0l8crossoriginanonymous /script scriptdefersrchttps://cdn.jsdelivr.net/npm/katex0.16.9/dist/contrib/auto-render.min.jsintegritysha384-VBxd3r6XgURycqtZ117nYw44OOcIax56Z4dCRWbxyPt0Koah1uHoK0o4/RRE05crossoriginanonymous /script scriptdocument.addEventListener(DOMContentLoaded, function () {renderMathInElement(document.body, {// customised options// • auto-render specific keys, e.g.:delimiters: [//此处可自定义修改//If you want to add support for inline math via $...$, be sure to list it after $$, as in the following. (Because rules are processed in order, putting a $ rule first would catch $$ as an empty math expression.){ left: $$, right: $$, display: true },{ left: $, right: $, display: false },{ left: \\(, right: \\), display: false },{ left: \\[, right: \\], display: true },],// • rendering keys, e.g.:throwOnError: false,});}); /script Include the partial in your templates like so: 在\themes\hugo-theme-stack\layouts\partials\head\head.html里加上下面的内容 // {{- template _internal/google_analytics.html . -}} // {{- partial head/custom.html . -}} //下面是要加的内容 {{ if or .Params.math .Site.Params.math }} {{ partial math.html . }} {{ end }}参考latex实现及hugo MathJax 我现在就用的是这个除了一些转义问题并没有遇到其他的问题。 配置操作 只有math.html的内容和KaTeX有所不同。 scripttypetext/javascriptasyncsrchttps://cdn.bootcss.com/mathjax/2.7.3/MathJax.js?configTeX-AMS-MML_HTMLorMML MathJax.Hub.Config({tex2jax: {inlineMath: [[$,$], [\\(,\\)]],displayMath: [[$$,$$], [\[\[,\]\]]],processEscapes: true,processEnvironments: true,skipTags: [script, noscript, style, textarea, pre],TeX: { equationNumbers: { autoNumber: AMS },extensions: [AMSmath.js, AMSsymbols.js] }}});MathJax.Hub.Queue(function() {// Fix code tags after MathJax finishes running. This is a// hack to overcome a shortcoming of Markdown. Discussion at// https://github.com/mojombo/jekyll/issues/199var all MathJax.Hub.getAllJax(), i;for(i 0; i all.length; i 1) {all[i].SourceElement().parentNode.className has-jax;}}); /scriptstylecode.has-jax {font: inherit;font-size: 100%;background: inherit;border: inherit;color: #515151;} /style 转义问题 换行 $$\displaylines{ z_{min}axby \\ \begin{cases} a_1xb_1y \le c_1 \\ a_2xb_2y \le c_2 \\ a_3xb_3y \le c_3 \end{cases}} $$ 显示效果 KaTeX parse error: Undefined control sequence: \displaylines at position 1: \̲d̲i̲s̲p̲l̲a̲y̲l̲i̲n̲e̲s̲{ z_{min}axby… $$\displaylines{ z_{min}axby \\\\ \begin{cases} a_1xb_1y \le c_1 \\\\ a_2xb_2y \le c_2 \\\\ a_3xb_3y \le c_3 \end{cases}} $$显示效果 KaTeX parse error: Undefined control sequence: \displaylines at position 1: \̲d̲i̲s̲p̲l̲a̲y̲l̲i̲n̲e̲s̲{ z_{min}axby… 图片 支持Typlog语法排版。 详见 『 Hugo 』Typlog Atlas
http://www.sczhlp.com/news/250962/

相关文章:

  • 自助建站软件公司wordpress sql文件大小
  • 垂直类网站怎么做推广试用虚拟主机不能创建网站
  • 2025 年 11 月高效沸腾干燥机,旋转闪蒸干燥机,空心桨叶干燥机厂家最新推荐,产能、专利、环保三维数据透视
  • 如何把未分配的硬盘空间分配到另一个磁盘?Windows 11,如何将未分配的磁盘分配给 C 盘?怎么把未分配的磁盘合并到d盘
  • 再见了ThreadLocal,我决定用ScopedValue!
  • Qoder 负责人揭秘:Qoder 产品背后的思考与未来发展
  • 网站域名后缀区别有网站源代码 怎么样建设网站
  • 建仿网站wordpress微博分享
  • dw网站开发环境创建免费网站
  • 密云区社区建设网站软件开发学院
  • 怎么做淘宝企业网站做网店的网站
  • 可以分4天做任务的网站石家庄造价信息网官网
  • 园区网互联及网站建设wordpress取回密码收不到邮件
  • 济南简单网站制作排名公司wordpress删除媒体库
  • 网站建设分几块如果网站没有做icp备案会被处罚
  • html5网站建设 教程视频sns社交网站 有哪些
  • 网站建设销售找客户话术做电影下载网站成本
  • 网站默认数据库地址成都百度推广公司电话
  • 高碑店住房和城乡建设局网站ghostwin8网站奖别人做
  • 闵行网站建设公司深圳外包公司网站
  • 珠海网站设计多少钱阿里云网站建设需要多少钱
  • 汕头cms建站模板设计公司logo大概需要多少钱
  • 网站设计建设合同是电子商务营销活动
  • 做网站需要掌握什么软件阿里云企业网站建设教程
  • 泊头做网站的有哪些上海派沃设计
  • 淘宝网站c 设计怎么做微信 小程序 wordpress
  • 做网站生意买螃蟹用花瓣网站上的图片做游戏行吗
  • 企业网站建设设计需要什么主要推广手段免费
  • 东营有做网站的公司p2p网站开发的流程图
  • asp.net 网站管理工具 遇到错误淄博市网站云平台