Daniel Thompson
Daniel Thompson

Reputation: 2351

SCSS function remains uncompiled in CSS output

Seems like I must have some syntax error with my function?

Defined as so:

@function v($i, $a: $ba) {
$ca: $i*$a;

$x: $r*(sin($ca) + $p*sin($q*$ca));
$y: $r*(cos($ca) - $p*cos($q*$ca));
$z: $r*sin(($q + 1)*$ca);

@return $x, $y, $z;
}

in my output style.css document I still see the function calls:

--v: v($i)

Upvotes: 1

Views: 92

Answers (1)

pentzzsolt
pentzzsolt

Reputation: 1131

In this case, you need to use interpolation where you call your function:

.selector {
  --v: #{v($i)};
}

Upvotes: 3

Related Questions