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

docs: add JSDoc documentation to core modules #110

Merged
merged 8 commits into from
Dec 14, 2024
Merged

docs: add JSDoc documentation to core modules #110

merged 8 commits into from
Dec 14, 2024

Conversation

gosuri
Copy link
Member

@gosuri gosuri commented Dec 10, 2024

This commit improves code documentation by adding JSDoc comments to core modules including wallet, storage, network, and main exports. The documentation provides clear descriptions of function parameters, return types, and module purposes to enhance code maintainability and developer experience.

- Add comprehensive JSDoc documentation to wallet management functions
- Document browser storage implementation for keytar replacement
- Add module-level documentation for main exports
- Document network functionality and types
- Improve type descriptions and function documentation

This commit improves code documentation by adding JSDoc comments to core
modules including wallet, storage, network, and main exports. The documentation
provides clear descriptions of function parameters, return types, and module
purposes to enhance code maintainability and developer experience.
@codecov-commenter
Copy link

codecov-commenter commented Dec 10, 2024

Codecov Report

Attention: Patch coverage is 87.50000% with 3 lines in your changes missing coverage. Please review.

Project coverage is 70.13%. Comparing base (7bd50c0) to head (8074637).

Files with missing lines Patch % Lines
src/certificates/certificate-manager/index.ts 0.00% 2 Missing ⚠️
src/sdl/sizes.ts 90.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #110      +/-   ##
==========================================
- Coverage   70.22%   70.13%   -0.09%     
==========================================
  Files          23       23              
  Lines         863      864       +1     
  Branches      211      231      +20     
==========================================
  Hits          606      606              
+ Misses        256      244      -12     
- Partials        1       14      +13     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

- Added detailed JSDoc comments for MAINNET_ID, SANDBOX_ID, TESTNET_ID, USDC_IBC_DENOMS, and AKT_DENOM.
- Improved code readability and maintainability by providing type annotations and descriptions for each export.

Signed-off-by: Greg Osuri <[email protected]>
- Add comprehensive JSDoc documentation to generate509.ts and generate509.spec.ts
- Document module purpose, interfaces, and function parameters
- Add detailed descriptions for certificate generation methods
- Include test suite documentation with test case descriptions
- Improve code readability with properly formatted parameter lists
- Remove unnecessary eslint-disable comment

Signed-off-by: Greg Osuri <[email protected]>
- Added detailed JSDoc comments to the CertificateManager class export, including usage examples.
- Enhanced documentation for the certificateManager instance with clear examples of import and usage.

Signed-off-by: Greg Osuri <[email protected]>
…dationError classes

- Enhanced the `ValidationError` class with detailed JSDoc comments, including usage examples for the `assert` method.
- Updated the `SdlValidationError` class to include comprehensive JSDoc comments and examples, improving code documentation and usability.
- Ensured consistency in documentation style across both error classes.

Signed-off-by: Greg Osuri <[email protected]>
…dationError classes

- Enhanced the `ValidationError` class with detailed JSDoc comments, including usage examples for the `assert` method.
- Updated the `SdlValidationError` class to include comprehensive JSDoc comments and examples, improving code documentation and usability.
- Ensured consistency in documentation style across both error classes.

Signed-off-by: Greg Osuri <[email protected]>
- Add comprehensive JSDoc for network type definitions (MainnetNetworkId, TestnetNetworkId, SandboxNetworkId)
- Document Window interface extension for Keplr wallet integration
- Include usage examples and parameter descriptions for getOfflineSignerAuto
- Improve type definitions readability with detailed descriptions

Signed-off-by: Greg Osuri <[email protected]>
- Added detailed JSDoc comments to the `fromString`, `validateGPU`, and `validateStorage` methods in the SDL class.
- Included usage examples in the JSDoc to demonstrate practical application of the methods.
- Improved code documentation for better readability and understanding.

Signed-off-by: Greg Osuri <[email protected]>
@@ -12,48 +16,101 @@ const {
BasicConstraints,
Extension,
ExtKeyUsage
// eslint-disable-next-line @typescript-eslint/no-var-requires
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could leave it there to avoid the lint issue

@gosuri gosuri merged commit 8be7bc2 into main Dec 14, 2024
1 of 3 checks passed
@gosuri gosuri deleted the jsdoc branch December 14, 2024 21:04
Copy link

🎉 This PR is included in version 0.11.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

3 participants