type-of() 函数主要用来判断一个值是属于什么类型:
返回值:
>> type-of(100)
"number"
>> type-of(100px)
"number"
>> type-of("asdf")
"string"
>> type-of(asdf)
"string"
>> type-of(true)
"bool"
>> type-of(false)
"bool"
>> type-of(#fff)
"color"
>> type-of(blue)
"color"
>> type-of(1 / 2 = 1)
"string"
Sass函数:Introspection 函数 -type-of()
原文:https://www.cnblogs.com/qjuly/p/9114014.html