- Use `>` (not code blocks) for blockquotes [1] - Read and consult the Guidelines and FAQ - If you dislike the "brutalist" aesthetic, you can use a userstyle to improve your experience. I use [2] - If you would prefer for comment to still be shown, but their replies hidden, you can change that with CSS [3] - If you want automatic code highlighting in code blocks, you can use a simple userscript [4]
[1] You can use this script to automatically convert `>` to blockquotes on page load. Could probably be done better but it works for me ¯\_(ツ)_/¯
[...document.querySelectorAll('.comment [class^="c"]')]
.filter(x => /(^|>)\s*>/m.test(x.innerHTML))
.forEach(x => {
const out = x.innerHTML
.replace(/(^|>)\s*>(.+?)(?=<|$)/mg, '$1<blockquote><p>$2</p></blockquote>')
.replace(/(?:<p>(<blockquote>))|(?:(<\/blockquote>)<\/p>)/g, '$1$2')
.replace(/<\/blockquote>[\s\n]*<blockquote>/g, '')
.replace(/(?:<i>(<blockquote>))|(?:(<\/blockquote>)<\/i>)/g, '$1$2')
.replace(/(?:(<blockquote>)<i>)|(?:<\/i>(<\/blockquote>))/g, '$1$2');
x.innerHTML = out;
});
[2] https://userstyles.org/styles/22794/a-dark-hacker-news
[3] .noshow.comment {
display: block;
}
[4] var script = document.createElement("script");
script.onload = () => {
const elems = [...document.querySelectorAll('code')];
elems.forEach(elem => hljs.highlightBlock(elem));
elems.filter(elem => elem.parentNode.tagName !== 'PRE').forEach(elem => elem.classList.add('not-block'));
};
document.head.appendChild(script);
script.src = 'https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.4.0/highlight.min.js';
I'd like to know what some of HN veterans do to make their experience better on this site. Do you access HN from Lynx on your custom-built Gentoo machine?