vole
Clone
Read only, no credentials:
https://rodent.software/git/vole.git
Write over SSH with a registered key:
git clone ssh://git@0.0.0.0:2222/vole.git
A free and open-source forge that lives in your Git repo.
Fix HTMX inline styles and Prism worker message parsing
ac00929fcb2269e874a0b7c0e6868885f57723ce · Keenan Nemetz · 12d ago · parent a76b2f38
Fix HTMX inline styles and Prism worker message parsing HTMX injects a <style> element for its indicator classes, which style-src 'self' blocks. Turn that off through its config meta tag and keep the indicator rules in the stylesheet instead. Prism installs its own worker message handler that expects a JSON string, so it threw JSON.parse on every structured job before prism-worker.js could highlight it. Disable that handler; the worker already owns the message path.
server/web/static/prism-worker.js +4−3
| @@ -6,10 +6,11 @@ | |||
| 6 | 6 | * swaps in the contents of each line cell, so line numbers and anchors are | |
| 7 | 7 | * present before this file runs and stay put afterwards. | |
| 8 | 8 | * | |
| 9 | * Prism's core detects a WorkerGlobalScope, but `manual` keeps it from also | ||
| 10 | * trying to walk a document that does not exist. */ | ||
| 9 | * Prism's core detects a WorkerGlobalScope, but `manual` keeps it from trying to | ||
| 10 | * walk a document that does not exist and `disableWorkerMessageHandler` keeps it | ||
| 11 | * from installing its own JSON-string listener on top of ours. */ | ||
| 11 | 12 | ||
| 12 | self.Prism = { manual: true }; | ||
| 13 | self.Prism = { manual: true, disableWorkerMessageHandler: true }; | ||
| 13 | 14 | importScripts('prism.min.js', 'prism-languages.min.js'); | |
| 14 | 15 | ||
| 15 | 16 | // splitLines closes the spans that are open at a newline and reopens them on the | |