-
Notifications
You must be signed in to change notification settings - Fork 54
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
BREAKING CHANGE: replace Buffer
with Uint8Array
#645
base: browser-compatibility
Are you sure you want to change the base?
Conversation
Buffer
with Uint8Array
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## browser-compatibility #645 +/- ##
=========================================================
- Coverage 87.19% 84.28% -2.91%
=========================================================
Files 120 120
Lines 24357 24352 -5
Branches 2508 2342 -166
=========================================================
- Hits 21238 20525 -713
- Misses 3076 3786 +710
+ Partials 43 41 -2
... and 9 files with indirect coverage changes Continue to review full report in Codecov by Sentry.
|
Buffer
with Uint8Array
Buffer
with Uint8Array
@@ -25,3 +26,11 @@ export function assertChainCode(chainCode: HexString): void { | |||
throw new Error(`chainCode must be length of 32 bytes!`); | |||
} | |||
} | |||
|
|||
export function hexifyWithout0x(value: BytesLike): string { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not extend the bytes.hexify
to accept hex string without 0x
@Keith-CY @homura After checking the related code last night, I suggest we postpone this PR. Reasons
Our goal here is to make Lumos run in browsers without extra configs.
When all these done, we release it with version |
Description
This PR is a part implementation of #597. There are some breaking changes in this PR because all
Buffer
in parameters and returns of methods are replaced withUint8Array
for browser compatibility.This PR targets the
browser-compatibility
branch instead of thedevelop
branch because the feature may be released at 0.23.0Type of change
Please delete options that are not relevant.
How Has This Been Tested?