Share via


How to hide warning scribblies in VS Code?

Question

Tuesday, December 29, 2015 3:23 AM

hi

how can i hide the warning scribblies in vs code, in html mode?

thx

All replies (3)

Wednesday, December 30, 2015 5:34 AM âś…Answered

Hi johny w,

Do you want to ignore these warning wave line in your html file?

In VS Code, we often change the settings for text editor through menu File -> Preferences -> Workspace Settings. It will open a Default Settings file which include all settings for VS Code.

I have found in Editor configuration part, there has no such settings about the warning wave line. And there also don't have HTML configuration part. But it has JavaScript configuration and CSS configuration, both of them has validate settings. Please set the settings in settings.json file in right-side of VS Code.

But I don't recommend you disable this settings, which is benefit to our deployment. If there any syntax error, the settings can help us trace this type error and warning us to correct it.

Best Regards,
Weiwei


Wednesday, December 30, 2015 7:49 PM

Hi Weiwei

I recommend both-- the option to toggle between showing and hiding warnings. 

I notice that the setting you recommended disables syntax-coloring-- i don't want to lose that. 

Just the wigglies. 

Update: maybe your fix was correct. Will have to work with it some more. 

ps, i noticed there's also a "user settings" option, which seems to contain the same settings as workspace settings. 

i also noticed a few related settings, including-

// Controls VSCode's JavaScript validation. If set to false both syntax and semantic validation is disabled
"javascript.validate.enable": true,

// Run linter checks for JavaScript files - overrides validate.lint.* settings.
"javascript.validate.semanticValidation": true,

// Check JavaScript files for syntax errors.
"javascript.validate.syntaxValidation": true,

// Controls various aspects of validation.

// Don't spare curly brackets.
"javascript.validate.lint.curlyBracketsMustNotBeOmitted": "ignore",

// Empty block should have a comment.
"javascript.validate.lint.emptyBlocksWithoutComment": "ignore",

// Use '!==' and '===' instead of '!=' and '=='.
"javascript.validate.lint.comparisonOperatorsNotStrict": "ignore",

// Missing semicolon.
"javascript.validate.lint.missingSemicolon": "ignore",

// Unexpected output of the 'typeof' operator.
"javascript.validate.lint.unknownTypeOfResults": "warning",

// Semicolon instead of block.
"javascript.validate.lint.semicolonsInsteadOfBlocks": "ignore",

// Function inside loop.
"javascript.validate.lint.functionsInsideLoops": "ignore",

// Function with lowercase name used as constructor.
"javascript.validate.lint.newOnLowercaseFunctions": "warning",

// Looks for mistyped triple-slash references.
"javascript.validate.lint.tripleSlashReferenceAlike": "warning",

// Unused local variable.
"javascript.validate.lint.unusedVariables": "warning",

// Unused local function.
"javascript.validate.lint.unusedFunctions": "ignore",

// Parameters don't match a function signature
"javascript.validate.lint.parametersDontMatchSignature": "ignore",

// Don't re-declare a variable and change its type.
"javascript.validate.lint.redeclaredVariables": "warning",

// Don't use an undeclared variable.
"javascript.validate.lint.undeclaredVariables": "warning",

// Don't use an unknown property.
"javascript.validate.lint.unknownProperty": "ignore",

// Don't require an unknown module.
"javascript.validate.lint.unknownModule": "ignore",

// Don't re-declare a variable type by an assignment.
"javascript.validate.lint.forcedTypeConversion": "warning",

// Only use numbers for arithmetic operations.
"javascript.validate.lint.mixedTypesArithmetics": "warning",

// Don't use instanceof with primitive types.
"javascript.validate.lint.primitivesInInstanceOf": "error",

// Function with return statement used as constructor.
"javascript.validate.lint.newOnReturningFunctions": "warning",

thx!


Thursday, December 31, 2015 2:45 AM

Hi johny w,

Yes, there are many settings in that file and I don't read all of them since I'm using Visual Studio IDE usually. If you are interesting with these settings, you can try them one by one.

In addition, if this problem has been resolved, please mark the helpful reply as answer, which is benefit to other communities who has the same problem. And if any other questions in future, please feel free to come back to our forum.

Best Regards,
Weiwei