Fix custom-property-no-missing-var-function
false positives for properties that can contain author-defined identifiers #5742
Closed
Description
What is the problem you're trying to solve?
Thanks to the CSS Houdini API, the property name of a custom property could appear in the value of some declarations, such as transition
(or more precisely, transition-property
). However, the current custom-property-no-missing-var-function
rule will report errors for these custom property names that are not wrapped in var()
.
What solution would you like to see?
One possibility is to not report transition
, etc. by default, but this could also produce breaking changes.
It is also possible to add options to the rule to ignore certain property names, as we did in property-no-vendor-prefix
.
module.exports = {
rules: {
'custom-property-no-missing-var-function': [true, { ignoreProperties: ['transition', 'transition-property'] }],
}
}