question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Lots of errors produced in WebStorm IDE with this plugin

See original GitHub issue

Describe the bug When including this plugin in my tsconfig.json, the Intellij WebStorm IDE reports hundreds of errors that look like this: Error:(54, 33) TS1155: 'const' declarations must be initialized. image

When I remove this plugin, these errors go away.

To Reproduce Steps to reproduce the behavior: Use WebStorm in a project with this plugin. My tsconfig using ts 3.9.5:

{
  "compilerOptions": {
    "outDir": "build/dist",
    "module": "esnext",
    "target": "es5",
    "lib": ["es6", "dom"],
    "sourceMap": true,
    "allowJs": true,
    "jsx": "react",
    "moduleResolution": "node",
    "baseUrl": ".",
    "rootDir": ".",
    "allowSyntheticDefaultImports": true,
    "esModuleInterop": true,
    "paths": {
      "~/*": ["src/*"]
    },
    "importsNotUsedAsValues": "preserve",
    "forceConsistentCasingInFileNames": true,
    "noImplicitReturns": true,
    "noImplicitThis": true,
    "noImplicitAny": true,
    "strictNullChecks": true,
    "suppressImplicitAnyIndexErrors": true,
    "noUnusedLocals": true,
    "isolatedModules": true,
    "plugins": [
      {
        "name": "typescript-plugin-css-modules",
        "options": {
          "customMatcher": "\\.css$"
        }
      }
    ]
  },
  "exclude": [
    "./node_modules",
    "build",
    "scripts",
    "acceptance-tests",
    "webpack",
    "src/setupTests.ts"
  ]
}

The TypeScript window in the IDE will call the TS service and find errors for you.

Expected behavior These errors wouldn’t show up.

Screenshots see above.

another very simple example:

image image

Desktop (please complete the following information):

  • OS: Mac OSX Catalina

Additional context We use CSS modules and some PostCSS features, though these errors seem to pop up in files that don’t do anything fancy like PostCSS’s nesting, too.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:17 (14 by maintainers)

github_iconTop GitHub Comments

1reaction
ekilahcommented, Sep 20, 2020

@mrmckeb there is no issue. I was just showing it working.

Seems to work great now.

1reaction
ChristopherHawscommented, Sep 18, 2020

@mrmckeb That fixed it for me in VS 2019. Everything seems to be working now! 👍

I do not receive the TS2339 error like @ekilah does.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error when downloading and Installing the plugin during ...
We are getting below error/ exception when multiple instance of IDE Is opened at the sometime and each instance of IDE is trying...
Read more >
Get results and fix problems | IntelliJ IDEA Documentation
IntelliJ IDEA performs code analysis and applies quick-fixes from the selected inspection profile to the detected issues. Alternatively, you can ...
Read more >
Start Failed, Internal error: recovering IDE to the working ...
There are multiple possible causes for this issue: broken or incompatible plug-in, corrupted IDE installation files, failed patch update, broken caches or ...
Read more >
InlineError - IntelliJ IDEs Plugin
Plugin for displaying errors message in the editor; inspired by Alexander's VSCode extension Error Lens. Source Code. License.
Read more >
IntelliJ highlights errors that don't exist
Try disabling all 3rd plugins, then File | Invalidate Caches/Restart.. | Invalidate and Restart and full project rebuild. If issue remains, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found