yarrichar
yarrichar9mo ago

intellisense not working

I'm using intellij (although this also seemed to be true in VSCode), and intellisense on my latest project doesn't seem to be working for convex functions (e.g. I can't ctrl click on api.x.y to jump to definition). Intellisense works fine for none convex typescript types. The confusing thing is that it is working for another project of mine. The only difference I can see is the convex version 1.11.0 vs 1.3.1. Downgrading didn't seem to help though. Are there any other settings I should be taking a look at? Thanks!
4 Replies
Michal Srb
Michal Srb9mo ago
Hey @yarrichar, I would check any tsconfigs between the two projects. If all else fails I'd start with a working project and then copy over the code, checking along the way that the types still work.
yarrichar
yarricharOP8mo ago
Hey @Michal Srb - thanks for the response. So I'm not sure exactly what the issue is, but it looks like it was getting confused when returning an unknown type from one of my actions. This seemed to call all convex based types to break. E.g. this didnt work:
return await externalApi.foo...
return await externalApi.foo...
But this did:
const result: any[] = await externalApi.foo...
return result;
const result: any[] = await externalApi.foo...
return result;
There may be something else going on though - I haven't been able to do a simple reproduction yet. The error I was getting on my action was:
TS7022: fetchClips implicitly has type any because it does not have a type annotation and is referenced directly or indirectly in its own initializer.
TS7022: fetchClips implicitly has type any because it does not have a type annotation and is referenced directly or indirectly in its own initializer.
Michal Srb
Michal Srb8mo ago
Actions | Convex Developer Hub
Actions can call third party services to do things such as processing a payment
yarrichar
yarricharOP8mo ago
Ok, cool. Glad I came up with the right approach - I guess all I would say is that it would be nice if it didn't break all types. But I guess that's hard to avoid.

Did you find this page helpful?