Module '"redux-saga/effects"' has no exported member 'call'.
tsopeh opened this issue · comments
Steps to reproduce
Try importing the call
(or any other) method in a .js or .ts file.
Description of the bug/issue
There is no code completion, suggestions or documentation in WebStorm and StackBlitz.
For .ts files IDE says: Module '"redux-saga/effects"' has no exported member 'call'.
Steps to reproduce the bug/issue
- Open this StackBlitz repro
- Take a look at the
index.ts
andindex-js.js
Example
import { call } from 'redux-saga/effects';
Actual results
IDE: Module '"redux-saga/effects"' has no exported member 'call'.
The Expected results
Successfully resolved import.
Environment information
- redux-saga version - 1.2.3
- babel / typescript setup - TS 4.9.3
Note
I've tried to bring the attention to this issue in the following issues, but got no answers for two weeks:
This must be an issue with StackBlitz because when I download the project locally and run it, there are no typescript issues. Could you please create a github repo that I could clone locally that replicates this issue?
It works well in VS Code (locally), but JS files in WebStorm (locally) do not recognise types for "redux-saga/effects". Many other libraries work fine.
Here's the exported StackBlitz project. You can export it as well by clicking to the "Download Project" button.
Running that project using vite
works fine. Running the project using VS Code
works fine. Is it possible this is an issue specifically with WebStorm
/Stackblitz
? Are there any other IDEs or bundlers that you notice the same typing issue?
I don't want to be dismissive and say this is a WebStorm
/Stackblitz
problem so I'm happy to guide anyone through this issue and accept any PRs that fix the problem. However, I don't personally have the bandwidth to debug an IDE specific issue with redux-saga
.
Thanks for raising this issue and again, happy to help where I can on fixing this issue.
I had the same issue using rollup
and this typescript plugin: https://www.npmjs.com/package/rollup-plugin-typescript2
Using the official plugin instead fixed the issue:
https://www.npmjs.com/package/@rollup/plugin-typescript