melte icon indicating copy to clipboard operation
melte copied to clipboard

ESLint configuration to ignore `$m:` label

Open davidsavoie1 opened this issue 3 years ago • 2 comments

Is there a way to configure ESLint to ignore the label $m: declaration? Right now, I get a '$m:' is defined but never used. no-unused-labels error. I know I could silence this type of error entirely as a rule Svelte override, but I am wondering if there's a way to disabled only this specific one, just as it is done for $: labels. Thanks in adavance!

davidsavoie1 avatar Aug 30 '21 13:08 davidsavoie1

This would probably have to be an option for eslint-plugin-svelte3 since it handles removing lint errors for the $: labels. It might be possible to create a separate eslint plugin to handle the $m labels, but I haven't found a way to so far.

zodern avatar Sep 06 '21 18:09 zodern

OK, I filed a new issue about that there. We'll see what comes out of it!

davidsavoie1 avatar Sep 13 '21 12:09 davidsavoie1