Today I Learned

hashrocket A Hashrocket project

Break long strings nicely with <wbr>

Are super-long strings (typically URLs) breaking out of an otherwise narrow column of text in your design? Sprinkle in some <wbr> tags; they don't take up any space, but provide the browser with safe places to break the string to a new line.

For example, this super-long URL will look normal, but if it's in a narrow area it'll linebreak at any of the <wbr> points:

<a href="">

Learn all about the <wbr> at MDN.

See More #html-css TILs