Sass Number Functions

You are Here:

Sass Number Functions

The following are the list of inbuilt number functions available in Sass language.

FunctionsExplanation
abs()Returns the absolute value of a number.
ceil()Returns the round of a number up to the next highest whole number.
comparable()Returns a Boolean value indicates whether number1 and number2 have compatible units.
floor()Returns the round of a number up to the next lowest whole number.
max()Returns the highest of one or more numbers. A list of numbers can be passed using ... (three dots).
min()Returns the lowest of one or more numbers. A list of numbers can be passed using ... (three dots).
percentage()Converts a unitless number to a percentage.
random()Returns a random decimal number between 0 and 1.
round()Returns the round of a number up to the nearest whole number.
unit()Returns a string representation of a number's units.
unitless()Returns whether a given number has a unit.

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