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

Re-consider having API docs for certain packages #835

Closed
arboleya opened this issue Mar 17, 2023 · 8 comments
Closed

Re-consider having API docs for certain packages #835

arboleya opened this issue Mar 17, 2023 · 8 comments
Assignees
Labels
docs Requests pertinent to documentation

Comments

@arboleya
Copy link
Member

At first, we spoke about eliminating Typedocs completely because the majority of files are not documented, and displaying purely mechanical and hollow documentation only adds noise, burying the rest underneath it.

However, a few places might have relevant docs to show.

These docs could be:

  1. Incorporated in the Guide in .md format (typedocs stay out)
  2. Re-enabled and put in a different menu section (typedocs returns)

Either way, we must first understand what packages fall in this category.

Then we can see what to do.

@arboleya arboleya added docs Requests pertinent to documentation refactor labels Mar 17, 2023
@arboleya
Copy link
Member Author

@luizstacio Want to chime in and list the packages you had in mind?

cc @Torres-ssf @FuelLabs/sdk-ts

@arboleya arboleya changed the title Re-enable API docs for certain packages Re-consider having API docs for certain packages Mar 17, 2023
@danielbate
Copy link
Contributor

I would like to see API documentation for certain packages within the TS SDK. Contextualised documentation and cookbooks (as we have currently) goes hand in hand with API documentation, and something I usually expect some level of with complex libraries. Done properly as well this is something that can just work alongside us as well rather than adding unnecessary overhead.

At a high level, I would like to see the entry point classes and methods documented for our core packages, as well as the parameters and config that they require, this could include:

  • Contract interaction, contract factory, methods to call contracts and the configuration / parameters required
  • Predicate instantiation within the SDK, transactional methods with predicates and setting data / configurables
  • Providers and it's methods, then coins, messages and resources (do we want to expose the GQL schema and autogenerated types here?)
  • Transactions including ScriptTransactionRequest and building out custom transactions (i.e. the methods available to the transaction request classes and params they expect, and any potential config)
  • Wallets, different types of wallet and the functions available to those types
  • Address, different types of addresses and the helpers to convert between them

I agree with the above points that it should be under a separate menu item to our current documentation menu items. I also think it is easier to maintain as it is directly to our business logic when using something like typedoc. And then easily incorporated to vitepress by outputting markdown.

I also agree with trying to reduce noise in code. We should do this in iterations, at first I would like to see the above just referenced and documented, potentially without any additional explanation to what is already available to us when highlighting functions in IDEs. Any additional noise could be added using type doc references?

@arboleya
Copy link
Member Author

@danielbate Thanks. Each of these bullet points can become an individual task. The first task should also add back typedocs and integrate it with vitepress in the current build routine.

@Torres-ssf I can't remember — did we make any progress experimenting with typedocs x vitepress in the past?

@danielbate
Copy link
Contributor

@arboleya @Torres-ssf I'd be happy to take those on 👍🏻 I can write up some tasks later on also

@danielbate danielbate self-assigned this Jul 13, 2023
@Torres-ssf
Copy link
Contributor

@arboleya, When we switched to Vitepress as our Doc engine, I didn't find a good native integration with Typedocs.

However, there might be improvements since then.

@danielbate
Copy link
Contributor

danielbate commented Jul 25, 2023

To reimplement API docs in the TS SDK documentation, the following tasks should be completed:

@sarahschwartz
Copy link
Contributor

For the docs hub, please make sure that the generated API subfolders and file names match the navigation names and structure.

@danielbate
Copy link
Contributor

Closing this as we have now reimplemented TypeDoc for API documentation. Will open further issues for changes and amendments.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Requests pertinent to documentation
Projects
None yet
Development

No branches or pull requests

4 participants