Alfonso Nishikawa Alfonso Nishikawa - 2 months ago 28
Sass (Sass) Question

In ExtJS, what is dynamic() in SCSS?

I am creating a SCSS for a component, and looking at ExtJS SCSS I find in Base.scss that a lot of variables (if not all) are defined as:

$form-field-empty-color: dynamic(gray);
$form-field-border-color: dynamic($neutral-color);
$form-field-border-width: dynamic(1px);
$form-field-border-style: dynamic(solid);
...


What is that
dynamic
function? My fu skill in search seems not to be the at the needed level :C

Thanks!

Answer

Ext uses Fashion, which is an extension of SASS. See: https://docs.sencha.com/cmd/6.x/fashion.html#Dynamic_Variables

It's somewhat similar to !default in SASS, but it defers computation until all variables are known.

Comments