Change SASS variable dynamically


Is there any way to change SASS variable dynamically?
For example, I have a variable as follow:

$lang: fa !default;

I want to change it at run-time to ‘en’. As i search the ionic forum, I can not find any good hint.
Is there anyway to change this variable dynamically?

Best Regards,


SASS is compiled into CSS so there’s no way you can change dynamically the content of a variable because CSS don’t have variables.

A solution is to use angular to change an existing class using ng-class or ng-style.