Skip to content
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

Sync Zoe JSDoc with API docs #4291

Open
Tracked by #1031
dckc opened this issue Jan 13, 2022 · 10 comments · May be fixed by #9182
Open
Tracked by #1031

Sync Zoe JSDoc with API docs #4291

dckc opened this issue Jan 13, 2022 · 10 comments · May be fixed by #9182
Assignees
Labels
audit-zestival Vulnerability assessment of ERTP + Zoe devex developer experience documentation Improvements or additions to documentation ERTP package: ERTP Zoe package: Zoe

Comments

@dckc
Copy link
Member

dckc commented Jan 13, 2022

What is the Problem Being Solved?

Zoe JSDoc that @erights has recently focussed on overlaps with end-user doc by @Chris-Hibbert and co. Let's sync them up somehow

Description of the Design

ref Dec 17 discussion

Also in the ZEstival, @Chris-Hibbert point out docs on Handling Authority

Security Considerations

IOU

Test Plan

the docs repo has tooling for testing examples

https://docs.agoric.com/reference/zoe-api/user-seat.html and related are sourced from JSDoc instead of Markdown

@dckc dckc added documentation Improvements or additions to documentation Zoe package: Zoe audit-zestival Vulnerability assessment of ERTP + Zoe labels Jan 13, 2022
@dckc dckc self-assigned this Jan 13, 2022
@dckc
Copy link
Member Author

dckc commented Jan 13, 2022

typedoc?

I looked at.typedoc earlier and passed on it because it's for .ts, not JSDoc... But if we head to .d.ts for apis, it could be a match!

@Tartuffo Tartuffo added MN-1 and removed Zoe package: Zoe labels Jan 20, 2022
@dckc dckc added the devex developer experience label Jan 20, 2022
@dckc
Copy link
Member Author

dckc commented Jan 20, 2022

@Tartuffo I would think that documentation for our smart contract platform doesn't become critical until after MN-1.

@turadg
Copy link
Member

turadg commented Sep 1, 2022

typedoc?

I looked at.typedoc earlier and passed on it because it's for .ts, not JSDoc... But if we head to .d.ts for apis, it could be a match!

Something that understands TypeScript will be necessary. TypeDoc (and presumably other type-smart tools) look for a unified project, so I think we'll need to #4404 to get any type-aware doc generators to work.

@dckc
Copy link
Member Author

dckc commented Jan 25, 2023

just discovered earlier exploration in this area:

@turadg
Copy link
Member

turadg commented Sep 18, 2023

#8343 is a fresh attempt.

One package without deps works, but when packages reference each other it chokes because our types don't all resolve as a single project. #4404 would solve that and may make the work worthwhile..

@dckc
Copy link
Member Author

dckc commented Nov 29, 2023

I think we're not quite finished with this one. #8343 says...

Should not be published for external consumption in its current state.

@dckc dckc reopened this Nov 29, 2023
@dckc
Copy link
Member Author

dckc commented Feb 2, 2024

recent work in the area:

@dckc
Copy link
Member Author

dckc commented Feb 2, 2024

closely related:

@dckc
Copy link
Member Author

dckc commented Mar 27, 2024

There's lots of relevant progress in Agoric/documentation#1038
in particular: https://3c691980.documentation-7tp.pages.dev/reference/agoric-sdk/modules/agoric_zoe.html

yay! I can find a type declaration for ContractMeta using full-text search!

hm... deeply imported stuff is kinda akward

Module: src/contractFacet/types-ambient
https://3c691980.documentation-7tp.pages.dev/reference/agoric-sdk/modules/agoric_zoe.src_contractFacet_types_ambient.html#contractmeta

and there's no prose. (what's the difference between canBeUpgraded and canUpgrade? are they synonyms?)

CopyRecord shows up in this module's list of types.
https://3c691980.documentation-7tp.pages.dev/reference/agoric-sdk/modules/agoric_zoe.src_contractFacet_types_ambient.html#copyrecord

HandleOffer follows the awkward pattern of separating a type declaration from an implementation even though there's only one implementation -- it's not an interface.
https://3c691980.documentation-7tp.pages.dev/reference/agoric-sdk/modules/agoric_zoe.src_contractFacet_types_ambient.html#handleoffer

Invitation has no prose.
https://3c691980.documentation-7tp.pages.dev/reference/agoric-sdk/modules/agoric_zoe.src_contractFacet_types_ambient.html#invitation

prose from README is missing. (artifact of markdown plugin, I think)
https://3c691980.documentation-7tp.pages.dev/reference/agoric-sdk/modules/agoric_zoe.html

and on and on....

cc @LuqiPan @Chris-Hibbert @erights @turadg @0xpatrickdev

@erights
Copy link
Member

erights commented May 8, 2024

typedoc does also work on jsdoc in *.js files

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
audit-zestival Vulnerability assessment of ERTP + Zoe devex developer experience documentation Improvements or additions to documentation ERTP package: ERTP Zoe package: Zoe
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants