Unexpected lint error when using "bypass" in a comment
See original GitHub issueLint error The use of the word "bypass" is not allowed, particularly with regards to bypassSecurityTrustHTML() and similar functions in Angular.
was thrown when “bypass” was used in a comment. This is unexpected. It should be possible to use the word in comments.
Helpful info to solve the issue:
- We can use the word “bypass” anywhere except for the following cases:
- Function
- Class
- All kinds of identifiers
- The lint check currently exists lint
general_purpose_linter
file (here), and it should either be modified or moved to third party linters to solve the issue.
Issue Analytics
- State:
- Created 3 years ago
- Comments:16 (15 by maintainers)
Top Results From Across the Web
warning Unexpected any. Specify a different type @typescript ...
Something that works for me when trying to bypass the same rule, specially for overloading methods is to use: // eslint-disable-next-line if ...
Read more >How to deal with lint warning "Unexpected any. Specify a ...
You can disable (and re-enable specific) eslint warnings at the line, block, file, an project levels. Here's how to disable the warning for ......
Read more >lint-staged throwing errors on pre-commit hook #11249 - GitHub
The only situation where that becomes a problem is where a maintainer wants to use Node 12 while doing a commit locally but...
Read more >Common issues and solutions - mypy 0.991 documentation
You can use the form # type: ignore[<code>] to only ignore specific errors on the line. This way you are less likely to...
Read more >no-console - ESLint - Pluggable JavaScript Linter
In general, calls using console should be stripped before being pushed to ... eslint no-console: "error" */ console.log("Log a debug level message.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@DubeySandeep As per offline discussion, kindly leave a comment here verifying if need this regex check or not. Thanks!
@OBITORASU Sorry for delayed response. Appreciate the effort you have put to explore the solutions and explaining it. But I am not sure if the approach (i.e the regex modification) you are suggesting would be the correct way. @DubeySandeep would you like to loop in here? One plausible way could be to shift the check from the general purpose linter to individual third party linters because I think we could implement it more easily there as per our requirements.