Skip to content

Added support for Prism.JS#54

Open
mauriciogior wants to merge 3 commits into
roryg:masterfrom
mauriciogior:master
Open

Added support for Prism.JS#54
mauriciogior wants to merge 3 commits into
roryg:masterfrom
mauriciogior:master

Conversation

@mauriciogior

Copy link
Copy Markdown

Hello,

I've added support for Prism js, changed the default post-content font (Merriweather) and removed a little stuff on CSS.

@mauriciogior

Copy link
Copy Markdown
Author

You are right, I should have make those changes in different commits.

"I've added support for Prism js, changed the default post-content font (Merriweather) and removed a little stuff on CSS."

@lazywei

lazywei commented Sep 24, 2014

Copy link
Copy Markdown

Any progress on this? Really want a better code highlighting @roryg @mauriciogior

@mauriciogior

Copy link
Copy Markdown
Author

@lazywei checkout my fork: https://github.com/mauriciogior/ghostwriter
It uses Prism JS. You can take a look at the documentation for further changes.

There is a sample on my website: http://mauriciogiordano.com/

@lazywei

lazywei commented Sep 24, 2014

Copy link
Copy Markdown

@mauriciogior I've checked it out, and I found a weird point: you may need to initiate the prism as well in default.hbs. For example, my fork use highlight.js:

<script>hljs.initHighlightingOnLoad();</script>

@mauriciogior

Copy link
Copy Markdown
Author

@lazywei

lazywei commented Sep 24, 2014

Copy link
Copy Markdown

That's true. However, NProgress.done will not be called at the first time user enter the blog.

@mauriciogior

Copy link
Copy Markdown
Author

@lazywei So you probably want to place the initializer on the same place you did with highlight.js.
We need also to reinitialize every time the ajax call is executed (inside the NProgress.done).

@lazywei

lazywei commented Sep 24, 2014

Copy link
Copy Markdown

I mean: you may also need to place the initializer to default.hbs. I agree with that we should have an initializer in NProgress.done

@mauriciogior

Copy link
Copy Markdown
Author

@lazywei There you go: mauriciogior@a73cee4

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

Successfully merging this pull request may close these issues.

3 participants