enten / hyde-y

Enhanced port of the Jekyll "Hyde" theme to Hugo
MIT License
88 stars 62 forks source link

Install highlight.js only if syntax theme set #41

Closed dusty-phillips closed 6 years ago

dusty-phillips commented 6 years ago

See https://github.com/enten/hyde-y/issues/40.

This makes it possible to use pygments/chroma without interference from highlight.js.

There are outstanding issues, but I don't know if they are related to the theme or to hugo itself:

enten commented 6 years ago

I don't follow hugo last releases.

Do you think that we can drop highlight.js for the builin hugo highlighting feature?

dusty-phillips commented 6 years ago

I'm not a hugo expert either. I've been happy with the built-in highlighter, and it gave me a feature that didn't work with highlight.js (line highlighting). I'm not sure if highlight.js has any features that are missing from the built-in parser.

If you were to remove highlight.js altogether, you'd need to make sure the configuration still works with markdown fenced code blocks. Otherwise it would break for anyone relying on Markdown. I suspect that's just a configuration setting, though. Also, people's syntax highlighting theme would break since the config would need pygmentsStyle instead of highlight to set the theme.

I think I'd leave highlight.js in place as an option and just document that both systems are available.