Skip to content

Remove the TypeScript/WASM package - #132

Draft
benma-agent wants to merge 1 commit into
BitBoxSwiss:masterfrom
benma-agent:benma-agent/remove-wasm-ts
Draft

Remove the TypeScript/WASM package#132
benma-agent wants to merge 1 commit into
BitBoxSwiss:masterfrom
benma-agent:benma-agent/remove-wasm-ts

Conversation

@benma-agent

Copy link
Copy Markdown
Contributor

The TypeScript client now lives in BitBoxSwiss/bitbox-api-ts.

Remove the WASM bindings, feature, serialization adapters, browser transports,
sandbox, and package build and CI tooling. Drop WASM size optimizations and
unused dependencies, and regenerate the protobuf code without WASM attributes.

  • Move Bitcoin's base64 feature to dev-dependencies for the PSBT example.
  • Remove U2FFraming and the unused Default implementation, retaining the U2fHid
    encoding and decoding methods used by physical devices and simulators.
  • Move the vendor and product IDs into usb.rs and remove the constants module.
  • Inline the private BitBox::from constructor into from_transport.

Consolidate the Rust and repository documentation in README.md, rename the Rust
changelog to CHANGELOG.md, and document the breaking changes for Rust consumers.

Refs: #60

The TypeScript client now lives in BitBoxSwiss/bitbox-api-ts.

Remove the WASM bindings, feature, serialization adapters, browser transports,
sandbox, and package build and CI tooling. Drop WASM size optimizations and
unused dependencies, and regenerate the protobuf code without WASM attributes.

- Move Bitcoin's base64 feature to dev-dependencies for the PSBT example.
- Remove U2FFraming and the unused Default implementation, retaining the U2fHid
  encoding and decoding methods used by physical devices and simulators.
- Move the vendor and product IDs into usb.rs and remove the constants module.
- Inline the private BitBox::from constructor into from_transport.

Consolidate the Rust and repository documentation in README.md, rename the Rust
changelog to CHANGELOG.md, and document the breaking changes for Rust consumers.

Refs: BitBoxSwiss#60

@cedwies cedwies left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Concept ACK

What do you plan doing with showMnemonic(), changePassword(), and bip85AppBip39(), which are currently stubs in the new package?

Are you planning to document the migration? The corrected declarations can break existing TS code.

Also, let json = serde_json::to_string(&signature)?; would not be possible anymore. Wouldn't it make sense to keep it here?

@benma

benma commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

What do you plan doing with showMnemonic(), changePassword(), and bip85AppBip39(), which are currently stubs in the new package?

See BitBoxSwiss/bitbox-api-ts#11

Are you planning to document the migration? The corrected declarations can break existing TS code.

Which corrected declarations? If you mean UInt8Array for sigs, that was mistyped in this repo and it does not seem to cause an issue, we already had some migrate to the new lib without issues.

Also, let json = serde_json::to_string(&signature)?; would not be possible anymore. Wouldn't it make sense to keep it here?

Not sure, could check some users of this lib, but I doubt it will be a big issue. It's a at most a small breaking change and the lib is on version 0.x, so acceptable 😄

@cedwies

cedwies commented Sep 8, 2026

Copy link
Copy Markdown
Collaborator

See BitBoxSwiss/bitbox-api-ts#11

Thanks!

that was mistyped in this repo and it does not seem to cause an issue

Good to hear, still, it depends on the implementation. A caller assigning signature.r from ethSignMessage() to a variable declared Uint8Array compiled before and fails now. IMO this warrants a small migration note, but I don't have a good overview about who is using our libs and it what way, so no strong opinion.

Not sure, could check some users of this lib, but I doubt it will be a big issue. It's a at most a small breaking change and the lib is on version 0.x, so acceptable

ACK

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants