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

markdown table with a indentation displays unsuccessfully on website. #3560

Closed
kwilove opened this issue May 24, 2019 · 7 comments
Closed

markdown table with a indentation displays unsuccessfully on website. #3560

kwilove opened this issue May 24, 2019 · 7 comments
Labels
question Needs help in usage stale

Comments

@kwilove
Copy link

kwilove commented May 24, 2019

Environment Info

Node version(node -v: Should be at least nodejs 6.9. If not, please update before posting an issue!): v10.15.1

Your site _config.yml (Optional):

Your theme _config.yml (Optional): yalia

Hexo and Plugin version(npm ls --depth 0):

Your package.json package.json:

For BUG

It display unsuccessfully markdown table with a indentation

markdown allows the table that adds a indentation, but this table displays unsuccessfully on website after executing hexo deploy command。

For example:
image

Display on website:
image

How should I solve this problem?

@yoshinorin
Copy link
Member

yoshinorin commented May 24, 2019

@kwilove
Because "4 spaces" means code block at a markdown specification.
Please see below.

Thanks :)

@kwilove
Copy link
Author

kwilove commented May 24, 2019

@yoshinorin
Thanks for your reply!

But i have a new question.

Use the same markdown text:
image

And then i open directly previous markdown file by browser, it will displays:
image

Why does it work on browser successfully? Do you know why the results were different?

thanks!

@yoshinorin yoshinorin reopened this May 24, 2019
@yoshinorin
Copy link
Member

yoshinorin commented May 24, 2019

@kwilove
Do you use a something extension to a browser?
My understanding, a browser cannot be rendering a markdown to HTML.

@kwilove
Copy link
Author

kwilove commented May 24, 2019

@yoshinorin
Yes, you are right.
I using a IDE called "Visual Studio Code" to write a markdown file, and the IDE has installed a plugin "Markdown Preview Enhanced", is this the cause?

@yoshinorin
Copy link
Member

yoshinorin commented May 24, 2019

@kwilove
OK. I got it. It is not VSCode plugins problem. Do you using hexo-renderer-marked?
hexo-renderer-marked is depended on marked. It seems fixed in markd #1446 and it's released in v0.6.2

Please see below demo.

We already bump to marked 0.6.x at hexo-renderer-marked v1.0.0

Would you please try to update your hexo-renderer-marked to 1.0.1?
Please be careful it has some breaking changes.

Below is dependency about hexo-renderer-marked 1.0.1

C:\Users\N.Yoshinori\tmp\marked-test
`-- hexo-renderer-marked@1.0.1
  +-- hexo-util@0.6.3
  | +-- bluebird@3.5.4
  | +-- camel-case@3.0.0
  | | +-- no-case@2.3.2
  | | | `-- lower-case@1.1.4
  | | `-- upper-case@1.1.3
  | +-- cross-spawn@4.0.2
  | | +-- lru-cache@4.1.5
  | | | +-- pseudomap@1.0.2
  | | | `-- yallist@2.1.2
  | | `-- which@1.3.1
  | |   `-- isexe@2.0.0
  | +-- highlight.js@9.15.6
  | +-- html-entities@1.2.1
  | `-- striptags@2.2.1
  +-- marked@0.6.2
  `-- strip-indent@2.0.0

I'm so sorry to wrong answer when first time...

@kwilove
Copy link
Author

kwilove commented May 24, 2019

@yoshinorin
Well,i will try it,thanks.

@stale
Copy link

stale bot commented Jul 23, 2019

This issue has been automatically marked as stale because lack of recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale label Jul 23, 2019
@stale stale bot closed this as completed Jul 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Needs help in usage stale
Projects
None yet
Development

No branches or pull requests

2 participants