kappa-db / workshop

let's learn how to write peer-to-peer applications in javascript!
https://kappa-db.github.io/workshop
71 stars 26 forks source link

Fix javascript syntax highlighting #34

Closed ralphtheninja closed 2 years ago

ralphtheninja commented 2 years ago

When rendering the markdown files into html, the js styling doesn't work. What do you think about only using the markdown files? We can remove all the build code and just focus on writing the markdown files that already looks nice on github with respect to js style etc.

Fix the syntax highlighting in the built html

hackergrrl commented 2 years ago

What styling isn't working? I was just leafing through the first few pages and it seems to look ok?

ralphtheninja commented 2 years ago

Html version:

Screenshot from 2022-02-05 11-37-56

Markdown version on github:

Screenshot from 2022-02-05 11-38-08

To me markdown on github simply looks better by default

hackergrrl commented 2 years ago

Oh, the syntax highlighting?

ralphtheninja commented 2 years ago

Oh, the syntax highlighting?

Yep! It would be nice if we could get that working in the html. Either that or, just enable the markdown to be "surfable", since the links in the markdown pages point to html pages and not to markdown.

ralphtheninja commented 2 years ago

@hackergrrl Btw, I added a project board for kappa here https://github.com/orgs/kappa-db/projects/1

hackergrrl commented 2 years ago

@ralphtheninja Full disclosure, I don't expect to have any capacity for this project any time in the near future :) So please go ahead with whatever changes you'd like to make that you feel will improve the accessibility & utility of this workshop. 💙

ralphtheninja commented 2 years ago

@ralphtheninja Full disclosure, I don't expect to have any capacity for this project any time in the near future :) So please go ahead with whatever changes you'd like to make that you feel will improve the accessibility & utility of this workshop. blue_heart

Ok. Will do my best! :heart:

ralphtheninja commented 2 years ago

@vweevers What would you use to render a markdown file with js code blocks to get a syntax highlighting similar to githubs js blocks?

EDIT: nvm, found highlight.js

ralphtheninja commented 2 years ago

Slightly better:

Screenshot from 2022-02-06 17-53-03

vweevers commented 2 years ago

@ralphtheninja Hi! I see you're already done but FWIW I used shiki for the common changelog website