stylelint-declaration-strict-value icon indicating copy to clipboard operation
stylelint-declaration-strict-value copied to clipboard

Ignore functions regex

Open silverwind opened this issue 2 years ago • 1 comments

I would like to allow certain functions like color-mix, but it seems the current ignoreFunction option is not flexible enough.

This should be flagged:

color: rgb(255 0 0);

This should be allowed:

color: color-mix(in srgb, var(--color-red), var(--color-blue));

Maybe have an ignoreFunctionRegex: /^color-mix$/ option?

silverwind avatar May 21 '23 22:05 silverwind

I would also like this option, and you could probably re-use the same keyword, like for "ignoreValues"

image Something like this:

"ignoreFunctions": {
	"": false,
	"/RegExp/[darken]": true,
	"/RegExp/[lighten]": true
},

Zeeex avatar Nov 27 '23 16:11 Zeeex