vscode-markdownlint icon indicating copy to clipboard operation
vscode-markdownlint copied to clipboard

Configure default severity

Open Bobronium opened this issue 3 years ago • 6 comments

I'm trying to configure default rules severity, but I guess, it doesn't work like that:

    "markdownlint.config": {
        "default": {
            "severity": "Information"
        },
    },

Is there a way to do it?

Upd.

Ok, I see now that severity is hardcoded here: https://github.com/DavidAnson/vscode-markdownlint/blob/522848a8cfe336bbc58056689e1a09f7dc8564f5/extension.js#L598

Can we make it configurable?

Bobronium avatar May 17 '22 11:05 Bobronium

Why do you want this? The current use of Warning seems appropriate according to the VS Code definitions:

	/**
	 * Represents the severity of diagnostics.
	 */
	export enum DiagnosticSeverity {

		/**
		 * Something not allowed by the rules of a language or other means.
		 */
		Error = 0,

		/**
		 * Something suspicious but allowed.
		 */
		Warning = 1,

		/**
		 * Something to inform about but not a problem.
		 */
		Information = 2,

		/**
		 * Something to hint to a better way of doing it, like proposing
		 * a refactoring.
		 */
		Hint = 3
	}

DavidAnson avatar Sep 20 '23 03:09 DavidAnson

I'm not saying it's wrong in any way.

It's usually configurable in other linters (pyright, etc.) and it gives certain flexibility when configuring a bunch of plugins/theme combo.

Bobronium avatar Sep 20 '23 17:09 Bobronium

Thanks. What changes if you were able to change these from Warning to Information? Are there different policies that kick in or something?

DavidAnson avatar Sep 20 '23 17:09 DavidAnson

It allows in turn to configure a visual scheme for one's taste.

For instance: https://github.com/Bobronium/vscode-pycharm-darcula-theme#linting-highlighting

Bobronium avatar Sep 20 '23 18:09 Bobronium