CSS Tips

CSS Tips Intro banner
Post Author - Marko by Marko | April 21, 2020

CSS tips and tricks you won’t see in most of tutorials.

What is CSS?


Cascading Style Sheets (CSS) is a style sheet language used for describing the presentation of a document written in a markup language like HTML. CSS is a main technology of the World Wide Web, alongside HTML and JavaScript.

CSS is designed to enable the separation of presentation and content, including layout, colors, and fonts. This separation can improve content accessibility, provide more flexibility and control in the specification of presentation characteristics, enable multiple web pages to share formatting by specifying the relevant CSS in a separate .css file, and reduce complexity and repetition in the structural content.

* Cursors

Did you know that you can use your own image, or even emoji as a cursor?

See the Pen Cursors by Marko (@denic) on CodePen.

* Smooth scrolling

Smooth scrolling without JavaScript, with just one line of CSS.

See the Pen CSS Smooth Scroll by Marko (@denic) on CodePen.

* Truncate text

Did you know that you can truncate text with plain CSS?

See the Pen Ellipsis by Marko (@denic) on CodePen.

* Truncate the text to the specific number of lines.

You can use “-webkit-line-clamp” property to truncate the text to the specific number of lines. An ellipsis will be shown at the point where the text is clamped.

Did you liked this article? Share it with your friends: