Hacker News new | ask | show | jobs
by kmfrk 5207 days ago
Related question: are all syntax highlighters awful to read for people who depend on accessibility tools, or is there actually a way to present code in a way that is accessible to these people?

Currenly, I just decorate the <pre> and <code> tags with CSS (as much as I would love line numbers).

1 comments

as much as I would love line numbers

I don't know if I understood you correctly, but you could add line numbers with before pseudo elements and use JavaScript to add numbers to its content. No need to mess with the markup, just CSS and JavaScript.