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

feat: convert to typescript #777

Merged
merged 4 commits into from Oct 4, 2022
Merged

Conversation

achingbrain
Copy link
Member

Converts this module to typescript

@achingbrain achingbrain changed the title feat!: convert to typescript feat: convert to typescript Sep 30, 2022
Comment on lines +73 to +75
apiAddr: nodes[id].apiAddr?.toString(),
gatewayAddr: nodes[id].gatewayAddr?.toString(),
grpcAddr: nodes[id].grpcAddr?.toString(),
Copy link
Member

Choose a reason for hiding this comment

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

we're changing the results from being '' (empty string) when undefined, to being undefined. Is this okay?

Comment on lines +125 to +127
apiAddr: nodes[id].apiAddr?.toString(),
gatewayAddr: nodes[id].gatewayAddr?.toString(),
grpcAddr: nodes[id].grpcAddr?.toString()
Copy link
Member

Choose a reason for hiding this comment

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

we're changing the results from being '' (empty string) when undefined, to being undefined. Is this okay?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, I think it's a bit better like as these fields will be stripped out on JSON encode now as they're undefined instead of being an empty string which is not a valid string representation of a multiaddr.

src/utils.ts Outdated Show resolved Hide resolved
src/utils.ts Outdated Show resolved Hide resolved
src/ipfsd-client.ts Outdated Show resolved Hide resolved
@achingbrain achingbrain merged commit ee3a35a into master Oct 4, 2022
@achingbrain achingbrain deleted the feat/convert-to-typescript branch October 4, 2022 12:45
github-actions bot pushed a commit that referenced this pull request Oct 4, 2022
## [12.1.0](v12.0.3...v12.1.0) (2022-10-04)

### Features

* convert to typescript ([#777](#777)) ([ee3a35a](ee3a35a))
@github-actions
Copy link

github-actions bot commented Oct 4, 2022

🎉 This PR is included in version 12.1.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.

None yet

2 participants