Comments (6)
Did you add a stylesheet? While Jekyll comes with built-in Rouge support, it does not come with a pre-defined stylesheet so coloring won't work out of the box. You can find various example stylesheets online, or you can use a tool* like pygments-css to generate one. Stick that stylesheet in the _sass
folder and make sure to import it in the assets/css/main.scss
file. Then your syntax highlighting should work.
*Correction: pygments-css
is actually a repo with a bunch of pre-generated pygments stylesheets you can use. Pygmentize is the actual tool
from jekyll-theme-prologue.
I was having the problem where Rogue didn't seem to do anything at all (not wrapping code keywords in <span>
elements, so there would be nothing to style for the Pygments stylesheet).
Then I discovered jekyll/jekyll#3641 (comment), removed highlight: rouge
from the root of _config.yml
and add syntax_highlighter: rouge
underneath the kramdown
node instead:
kramdown:
syntax_highlighter: rouge
from jekyll-theme-prologue.
Hi CodeRedPaul, I'm in the same boat, I can't use 'Rouge'.
I use jekyll v3.7.3, rouge v2.2.1, jekyll-theme-prologue v0.3.2 on Ubuntu
from jekyll-theme-prologue.
@Drakmyth I'm not that familiar with Jekyll, do you mind helping me out a bit?
Say I want to use monokai.css
from the stylesheets online, I would put that file directly in _sass
folder, then what statement would I use to import it in the assets/css/main.scss
file? Something along the lines of @import "monokai.css"
?
from jekyll-theme-prologue.
@Drakmyth @LoicH I managed to make it work by sticking the monokai.css
in the the assets/css/
folder and importing in assets/css/main/scss
from jekyll-theme-prologue.
Yep, either location works. It just changes the path you pass into the import statement. In my setup, I have (for example) _sass/monokai.scss
and then in assets/css/main.scss
I have @import "highlight";
but you can do it how you have it as well.
from jekyll-theme-prologue.
Related Issues (20)
- page icon
- blog FA icons for articles overlap text HOT 1
- Google analytics not working
- [noob] Liquid Exception: Liquid syntax error (line 1): Tag '{%- comment -%}'
- Scrolly error on pages with exactly one section HOT 1
- A Question HOT 1
- Accessibility errors found in your template
- Cannot sort a null object error HOT 1
- Absolute link paths
- Add option to have whatsapp url with Font Awesome's Whatsapp icon HOT 1
- Adding google scholar & research gate to social sites HOT 1
- remote theme issues with github pages HOT 2
- Looking for someone to maintain this theme. HOT 1
- Page content is extending behind nav bar HOT 2
- Sidebar hover and link doesn't work HOT 1
- Breaks with newer versions?
- navbar breaks when there is a tag named "Header" in the Markdown HOT 1
- Add search
- Add LaTeX functionality (New functionality)
- Print with only html instead of including css HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jekyll-theme-prologue.