Ask coding questions

← Back to all posts
jsDocs + Node.js Require Glich???
ErrorbotTHE2nd (7)

So I have a class inside called CFrame.js, and in that file, I've imported a class called Vecter3.js as seen before the class I declared.

Now, in that class, I have a "private" method, that is using JsDoc to help me and other people understand what the function does, just by hovering over it.

but for some reason, v3 is still type any when I want it to be type Vector3 as seen in this image.

Also, what happened there, before it only showed the bottom two, then after a reload, it's showing both???

Do you think I should make a bug report???

Also I did some testing and found out it works if I don't use Vector3 or Object as the type...

Answered by Coder100 (19277) [earned 5 cycles]
View Answer
Comments
hotnewtop
Coder100 (19277)
  1. yes, yes you should, i think replit has a bug where there are 2 analyzers, and they both suggest the same thing at the same time
ErrorbotTHE2nd (7)

@Coder100 okay ill do that, but can you answer the question??

Coder100 (19277)

what's your question exactly?
you have 2 from what i can tell
1. why are there 2 suggestions (my analyzer theory)
2. is it a bug (probably)
@ErrorbotTHE2nd

ErrorbotTHE2nd (7)

@Coder100 I know this is 7 hours later but, the problem is that whenever I hover over my function, the param v3 show type any when I want it to say Vector3 (a class required from Vector3.js)

Also, I did some testing and found out it works if I don't use Vector3 or Object as the type...

Coder100 (19277)
  1. because it's a bug?? The analyzer I believe gets confused with imports or something

@ErrorbotTHE2nd