Unfortunately, at this time (May 2022) JetBrains does not appear to keep an up-to-date list of inspection IDs (what I'll call shortName
s) as part of their public online documentation for all products (e.g. there is a page called List of Java inspections, but it doesn't appear to include the shortName
s).
If you are a JetBrains customer and this is something you would like then I would encourage you to send feedback to them with suggestions for how the software could be improved. (e.g. on a community forum or YouTrack).
Thankfully, there are some ways to ascertain these shortName
s:
1. Use the context menu
Right-click near the "red squiggle", select "Show Context Actions", click directly on the arrow, and click "Suppress for statement". This should generate a comment above the line, e.g. // noinspection NpmUsedModulesInstalled
, which then suppresses the inspection for the following line (making the "red squiggle" go away)

Personally, I think having to directly click that arrow symbol is bad UX because it violates the usual convention of the arrow merely signaling that selecting the item, not only the arrow, will open a submenu. Using "..." or "More..." or something would have been more clear. Additionally, it feels inconsistent to have to show an additional menu to reveal the "Suppress ..." options for JetBrains' inspections meanwhile using code quality tools/plugins like eslint
causes "Suppress ..." options to be listed on the first level (which, in my opinion, is the most appropriate place for them).
2. Peek at a cheat sheet
Various people have uploaded (unofficial) lists of the inspection names for convenient reference. Here are some:
3. Dig into the IDE's installation files
In my case, I searched through files in my WebStorm installation folder (e.g. C:\Users\me\AppData\Local\JetBrains\Toolbox\apps\WebStorm\ch-0\221.5080.193
) and found plugins/JavaScriptLanguage/lib/JavaScriptLanguage.jar
(which is a compressed archive, using ZIP format, whose contents can can be extracted) and found that the META-INF\plugin.xml
file it contained had the information I wanted in the shortName
attribute of elements that looked like this:
<localInspection
language="JavaScript"
groupPath="JavaScript and TypeScript"
shortName="JSRemoveUnnecessaryParentheses"
key="unnecessary.parentheses.display.name"
groupKey="js.code.style.issues.group.name"
enabledByDefault="true"
level="INFORMATION"
cleanupTool="true"
implementationClass="com.intellij.lang.javascript.inspections.JSRemoveUnnecessaryParenthesesInspection"
/>