isVariable.cjs 388 B

123456789101112131415
  1. // NOTICE: This file is generated by Rollup. To modify it,
  2. // please instead edit the ESM counterpart and rebuild with Rollup (npm run build).
  3. 'use strict';
  4. /**
  5. * Check whether a word is a variable i.e var(--custom-property).
  6. *
  7. * @param {string} word
  8. * @returns {boolean}
  9. */
  10. function isVariable(word) {
  11. return word.toLowerCase().startsWith('var(');
  12. }
  13. module.exports = isVariable;