Sass str-length() Function

You are Here:

Sass str-length() Function

The str-length() function returns the number of characters in a string.

Example

SASS TO CSS CONVERTER
//Check your console @debug str-length("sans-serif"); // 10 @debug str-length("30px"); // 4 @debug str-length(""); // 0

Syntax

str-length($string)

Parameter Value

ValueTypeExplanation
$stringOptionalA string.

Return Value

ValueExplanation
NumberReturns the number of characters in $string.

Reminder

Hi Developers, we almost covered 99.1% of Sass Tutorials with examples for quick and easy learning.

We are working to cover every Single Concept in Sass.

Please do google search for:

Join Our Channel

Join our telegram channel to get an instant update on depreciation and new features on HTML, CSS, JavaScript, jQuery, Node.js, PHP and Python.

This channel is primarily useful for Full Stack Web Developer.

Share this Page

Meet the Author