-
Notifications
You must be signed in to change notification settings - Fork 107
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
better type information (typescript) #620
Comments
One of the primary goal for the next major release (7.0) will be improved typings. Sadly this is fairly tedious and requires a lot of manual verification because the HTTP API docs are sometimes a bit ambiguous. |
@pluma glad to here that. Is there something like a roadmap for arangojs? |
No but if it's any consolation arangojs 7 is exactly what I'm currently working on. |
Great, thank you |
@pluma Is there any repository (branch or something) which can already be used? Because of the typing stuff is really a pain... |
You can check out and build the |
@pluma Any timeframe when this (v7) will be released? |
@pluma Thank you for the great work ! Thank you again ! |
@pluma Can you please give us an update about the typescript support? Current situation is far away from good. (BTW, is this an "official" ArangoDb project?) |
@pluma I suggest that you release alpha or beta versions so we can try it out easier and could help to polish it better sooner. |
Hello, thanks for working on improving TS experience for working with arangojs. Is there any time-frame or at least rough estimate when to expect 7.0? |
My current plan is to release a preview version at some point in May. The CHANGELOG seems to be fairly complete and what's mostly missing right now is inlining the documentation (which also means properly documenting all the types and attributes in cases where the previous written documentation has gone out of sync with the actual code). Before releasing a preview version, I would like to merge the PR. For this to happen I wanted to be certain what the breaking changes will be so I can release a minor version that will try to narrow the gap by adding new methods and tagging methods that will be removed as deprecated where possible. As this entire ordeal takes a lot more effort than I originally anticipated, I will probably release the preview version from within the WIP branch instead, even if this messes up the GitHub tags later. |
Good news everyone, I've released the current state of the https://github.com/arangodb/arangojs/releases/tag/v7.0.0-preview.0 You can install this version using the Please be aware that this release includes a large number of breaking changes. The preview release also still lacks a lot of the inline documentation that has not yet been finalized. As this is a preview release there is also no guarantee of no further breaking changes before the final 7.0.0 release. |
I suggest subscribing to #660 if you want to track the release of v7 more closely. v7.0.0-preview.1 has been released today. There likely won't be any significant API changes outside the methods for which documentation has not yet been inlined: https://github.com/arangodb/arangojs/tree/v7/docs/Drivers/JS/Reference |
@Sharakai So if I understand you correctly, you suggest having the return type tied to the |
Although arangojs is written in typescript the type information is not really super strong.
e.g. when working with collections (super class BaseCollection) there are several methods which return type "Promise<any>". (and so on...)
Also, not all types are accessible via importing from 'arangojs'
e.g. when I want to use the type 'ArrayCursor' I have to:
import { ArrayCursor } from 'arangojs/lib/async/cursor';
orimport { ArrayCursor } from 'arangojs/lib/cjs/cursor';
Would it be possible to provide better type information?
The text was updated successfully, but these errors were encountered: