summaryrefslogtreecommitdiff
path: root/node_modules/doiuse/data/features/css-variables.js
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/doiuse/data/features/css-variables.js')
-rw-r--r--node_modules/doiuse/data/features/css-variables.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/node_modules/doiuse/data/features/css-variables.js b/node_modules/doiuse/data/features/css-variables.js
new file mode 100644
index 00000000..fecc07b4
--- /dev/null
+++ b/node_modules/doiuse/data/features/css-variables.js
@@ -0,0 +1,8 @@
+/**
+ * @param {import('postcss').ChildNode} rule
+ * @return {boolean}
+ */
+export default (rule) => {
+ if (rule.type !== 'decl') return false;
+ return (rule.prop.startsWith('--') || rule.value.includes('var('));
+};