UNPKG

359 BJavaScriptView Raw
1'use strict';
2
3/**
4 * Check whether a math function is standard
5 *
6 * @param {string} mathFunction
7 * @returns {boolean}
8 */
9module.exports = function isStandardSyntaxMathFunction(mathFunction) {
10 // SCSS variable
11 if (mathFunction.includes('$')) {
12 return false;
13 }
14
15 // Less variable
16 if (mathFunction.includes('@')) {
17 return false;
18 }
19
20 return true;
21};