gobengo / distbin

distributed social pastebin using Activitypub
https://distbin.com
Apache License 2.0
78 stars 8 forks source link

Feature Request : Code and Syntax Highlighting #16

Closed yalh76 closed 5 years ago

yalh76 commented 5 years ago

I don't know if it's planned but it would be awesome to have Code and Syntax Highlighting, like describe here: https://github.com/adam-p/markdown-here/wiki/Markdown-Cheatsheet#code-and-syntax-highlighting

I joined an example: How to write a post: distbin-write

How it could be read: distbin-read

gobengo commented 5 years ago

Here is where the activity.object.content gets sanitized and otherwise processed into a final html string to use on the distbin-html/an-activity pages. Easiest implementation of this would be to pass it through one more function to add syntax highlighting. https://github.com/gobengo/distbin/blob/master/src/distbin-html/an-activity.ts#L174

yalh76 commented 5 years ago

First try to implement : https://github.com/gobengo/distbin/pull/26