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

Server crash (Syntax highlighter) #11

Closed
adun opened this issue May 26, 2013 · 4 comments
Closed

Server crash (Syntax highlighter) #11

adun opened this issue May 26, 2013 · 4 comments

Comments

@adun
Copy link

adun commented May 26, 2013

I'm getting an error with one of my wiki page:

Error: You need to pass a language obtained via "getLanguage"
Please report this to https://github.com/chjj/marked.
    at Object.highlight (/opt/jingo/node_modules/node-syntaxhighlighter/node-syntaxhighlighter.js:81:24)
    at Object.Marked.setOptions.highlight (/opt/jingo/lib/renderer.js:12:16)
    at Parser.tok (/opt/jingo/node_modules/marked/lib/marked.js:837:33)
    at Parser.parse (/opt/jingo/node_modules/marked/lib/marked.js:778:17)
    at Function.Parser.parse (/opt/jingo/node_modules/marked/lib/marked.js:765:17)
    at marked (/opt/jingo/node_modules/marked/lib/marked.js:1017:19)
    at Object.Renderer.render (/opt/jingo/lib/renderer.js:77:12)
    at exports.miscPreview (/opt/jingo/routes/index.js:423:23)
    at callbacks (/opt/jingo/node_modules/express/lib/router/index.js:161:37)
    at param (/opt/jingo/node_modules/express/lib/router/index.js:135:11)

I suspect yaml syntax.

@claudioc
Copy link
Owner

HI, can you please show me the config file and (eventually) the page (or at least the part of the page which craches). Feel free to use my email address: cld@ccl.me

Thanks!

@adun
Copy link
Author

adun commented May 26, 2013

Please check your mails for the config file and full page details

Steps to reproduce

  • Create a new wiki page
  • Add the following
  • Preview the page
  • Server should have crashed

@claudioc
Copy link
Owner

It was indeed caused by using an unknown language for the syntax highlighter. I've fixed it and added a comment con the Readme to have the list of supported languages :)

Thanks 👍

@adun
Copy link
Author

adun commented May 26, 2013

You're welcome, it's my pleasure to improve this project.

yusiwen added a commit to yusiwen/jingo that referenced this issue Dec 11, 2016
1. Use 'markdown-it-toc-and-anchor' plugin to extends '@[toc]' string to TOC
2. Add some css styles of TOC and link anchors

Fixes claudioc#11
yusiwen added a commit to yusiwen/jingo that referenced this issue Dec 11, 2016
Generate toc on the client side
Add toc to the right side of content

Fixes claudioc#11
Fixes claudioc#12
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

2 participants