Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hexo 换行问题 #1672

Closed
payne4handsome opened this issue May 20, 2017 · 4 comments
Closed

Hexo 换行问题 #1672

payne4handsome opened this issue May 20, 2017 · 4 comments

Comments

@payne4handsome
Copy link

Expected behavior (预期行为)

在文本编辑器中回车,在页面上不换行

Actual behavior (实际行为)

在文本编辑器中回车,在页面上换行了,安装markdown的语法应该是
两个空格加回车才是换行呀

Steps to reproduce the behavior (重现步骤)

NexT Information

Add the ✔ sign before an item which is affected by this behavior.

NexT Version:

  • Master
  • Latest Release
  • Old version -

NexT Scheme:

  • All schemes
  • Muse
  • Mist
  • Pisces

Other Information (Like Browser, System, Screenshots)

@doachit
Copy link

doachit commented Jun 28, 2017

我也很纠结这个换行的问题,如果自己换行的话网页排版出来实在是丑的可以。。。。现在我只能一行写好长好长才能换个行好烦

@michaelHL
Copy link

michaelHL commented Jul 17, 2017

与NexT主题无关, Hexo利用自带的解析器对md源文件进行解析. 也许可行的解决方案:

  1. 安装 hexo-renderer-marked

    npm install hexo-renderer-marked --save

    不过最新的Hexo貌似已经装上了这个.

  2. 在站点配置文件中加上:

    marked:
      gfm: true
      pedantic: false
      sanitize: false
      tables: true
      breaks: false
      smartLists: true
      smartypants: true
      modifyAnchors: ''
      autolink: true

    这样就可以在一行自由敲回车了:satisfied:

@ivan-nginx
Copy link
Collaborator

@payne4handsome solved?
And is i see and as write before, trouble in global Hexo, not in theme Next.

@michaelHL
Copy link

michaelHL commented Jul 22, 2017

@ivan-nginx It's really the 'trouble' in hexo, and was solved in several issues of hexo(and it works well for me), this issue should be closed.

Ref

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants