Applying Scroll Bar (Horizontal & Vertical) to Code Snippets

I like how in some of my code snippets a horizontal scroll bar that is applied for code that is very wide.

I have a post I’m drafting that has a lot of snippets. I’d like to apply a vertical scroll bar for any code snippet longer than 4 rows. Any way to manually do this?

Thanks in advance,
Jesse

That’s controlled via CSS. By default the scrollbar happens when it’s taller than 500px. You can make it happen early in a theme component as explained in How to make CSS changes on your site.

2 Likes