Open rxliuli opened 4 years ago
实测了一下,是因为不支持 tsx 的语法高亮时默认将之当成了普通的 markdown 中的 HTML(默认不应该当作文本么?)
不应该吧,我看看你的文档中的代码怎么写的。
下面这段代码
import React, { Component } from 'react'
class HelloWorld extends Component {
logMsg = () => {
console.log('msg')
}
render() {
return (
<div>
<h1>hello world</h1>
<button onClick={this.logMsg}>打印</button>
</div>
)
}
}
export default HelloWorld
将语言标识修改为 tsx 就可以看到问题了
而且因为被当成 HTML 渲染行号也对不上。。。
嗯,是有这个问题
嗯,是有这个问题
我看那个库也只有一个文件,如果作者一直不修复的话,可以直接内嵌到这个项目里
https://godweiyang.com/2018/04/13/hexo-blog/#toc-heading-14 这篇文章后半部分有解决方法
很遗憾,这个博客的代码高亮本身就有问题
请问您解决这个问题了吗 我也遇到了
没,改成 jsx 了
没,改成 jsx 了
这个怎么改的 您写了博客记录吗?
就是改成 jsx 语言标识了啊,在 markdown 源文件里
swust-zyh notifications@github.com 于 2020年5月26日周二 下午12:31写道:
没,改成 jsx 了
这个怎么改的 您写了博客记录吗?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/blinkfox/hexo-theme-matery/issues/304#issuecomment-633802152, or unsubscribe https://github.com/notifications/unsubscribe-auth/AF3MF4FKMPU4464GU2TDBXTRTNA37ANCNFSM4KPFZCTQ .
就是改成 jsx 语言标识了啊,在 markdown 源文件里 swust-zyh notifications@github.com 于 2020年5月26日周二 下午12:31写道: … 没,改成 jsx 了 这个怎么改的 您写了博客记录吗? — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub <#304 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AF3MF4FKMPU4464GU2TDBXTRTNA37ANCNFSM4KPFZCTQ .
就是改成 jsx 语言标识了啊,在 markdown 源文件里 swust-zyh notifications@github.com 于 2020年5月26日周二 下午12:31写道: … 没,改成 jsx 了 这个怎么改的 您写了博客记录吗? — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub <#304 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AF3MF4FKMPU4464GU2TDBXTRTNA37ANCNFSM4KPFZCTQ .
ok
https://godweiyang.com/2018/04/13/hexo-blog/#toc-heading-14 这篇文章后半部分有解决方法 解决不了我 尝试了
我一开始的情况和楼主一样,后来我在源码里添加了jsx,正常了,去掉jsx,也正常了,我懵逼了,不是缓存的问题
不支持 tsx
tianyichuxin notifications@github.com 于 2020年6月4日周四 下午6:14写道:
我一开始的情况和楼主一样,后来我在源码里添加了jsx,正常了,去掉jsx,也正常了,我懵逼了,不是缓存的问题
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/blinkfox/hexo-theme-matery/issues/304#issuecomment-638757482, or unsubscribe https://github.com/notifications/unsubscribe-auth/AF3MF4AHE6XQEY5OLUCUWO3RU5XYZANCNFSM4KPFZCTQ .
不支持 tsx tianyichuxin notifications@github.com 于 2020年6月4日周四 下午6:14写道: … 我一开始的情况和楼主一样,后来我在源码里添加了jsx,正常了,去掉jsx,也正常了,我懵逼了,不是缓存的问题 — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub <#304 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AF3MF4AHE6XQEY5OLUCUWO3RU5XYZANCNFSM4KPFZCTQ .
我内容里一开始只是js,后来把js改完jsx,就没问题了,重点来了,我又改为js,没有用tsx,而且正常了,而且是所有有问题的页面都正常了
不支持tsx tianyichuxin notifications@github.com 于2020年6月4日周四下午6:14写道: … 我一开始的情况和楼主一样,后来我在源码里添加了jsx,正常了,去掉jsx,也正常了,我懵逼了,不是缓存的问题— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub < #304 (comment) >, or unsubscribe < https://github.com/notifications/unsubscribe-auth/AF3MF4AHE6XQEY5OLUCUWO3RU5XYZANCNFSM4KPFZCTQ > .
还有一个问题,就是你的右上角的关闭和复制有没有问题?我这边不能复制和关闭
这个倒没有
tianyichuxin notifications@github.com 于 2020年6月5日周五 上午12:23写道:
不支持tsx tianyichuxin notifications@github.com 于2020年6月4日周四下午6:14写道: … <#m2711425554499153291> 我一开始的情况和楼主一样,后来我在源码里添加了jsx,正常了,去掉jsx,也正常了,我懵逼了,不是缓存的问题— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub < #304 (comment) https://github.com/blinkfox/hexo-theme-matery/issues/304#issuecomment-638757482
, or unsubscribe < https://github.com/notifications/unsubscribe-auth/AF3MF4AHE6XQEY5OLUCUWO3RU5XYZANCNFSM4KPFZCTQ .
还有一个问题,就是你的右上角的关闭和复制有没有问题?我这边不能复制和关闭
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/blinkfox/hexo-theme-matery/issues/304#issuecomment-638962461, or unsubscribe https://github.com/notifications/unsubscribe-auth/AF3MF4D5OOUUUFJJLR5RM5LRU7C65ANCNFSM4KPFZCTQ .
图解
发生问题的仓库: https://github.com/rxliuli/blog
配置项
不知道发生了什么,有什么解决方案么?