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

Add some WASM APIs #39

Merged
merged 9 commits into from
Jul 27, 2022
Merged

Add some WASM APIs #39

merged 9 commits into from
Jul 27, 2022

Conversation

matheus23
Copy link
Member

@matheus23 matheus23 commented Jul 20, 2022

  • Provide metadata info in ls
  • Expose base_history_on function
  • Expose load function

Fixes #34

- Provide metadata info in `ls`
- Expose `base_history_on` function
- Expose `load` function
@matheus23 matheus23 marked this pull request as ready for review July 22, 2022 14:18
@codecov-commenter
Copy link

Codecov Report

Merging #39 (6fd56b9) into main (0a6d8b6) will increase coverage by 2.96%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##             main      #39      +/-   ##
==========================================
+ Coverage   77.11%   80.07%   +2.96%     
==========================================
  Files          17       18       +1     
  Lines         970     1275     +305     
==========================================
+ Hits          748     1021     +273     
- Misses        222      254      +32     
Impacted Files Coverage Δ
crates/fs/common/metadata.rs 68.18% <ø> (ø)
crates/wasm/fs/public/directory.rs 0.00% <ø> (ø)
crates/fs/common/error.rs 0.00% <0.00%> (-50.00%) ⬇️
crates/fs/private/hamt/hash.rs 97.22% <0.00%> (-2.78%) ⬇️
crates/fs/private/hamt/pointer.rs 66.15% <0.00%> (-2.14%) ⬇️
crates/wasm/fs/blockstore.rs 0.00% <0.00%> (ø)
crates/fs/private/hamt/error.rs
crates/fs/private/namefilter/bloomfilter.rs 88.88% <0.00%> (ø)
crates/fs/private/namefilter/namefilter.rs 90.90% <0.00%> (ø)
... and 4 more

📣 Codecov can now indicate which changes are the most critical in Pull Requests. Learn more

@appcypher
Copy link
Member

appcypher commented Jul 22, 2022

Thanks for tackling these problems. I have a few comments on some of type conversions. They are just idiom nitpicks.

crates/wasm/fs/metadata.rs Outdated Show resolved Hide resolved
crates/wasm/fs/metadata.rs Outdated Show resolved Hide resolved
crates/wasm/fs/metadata.rs Show resolved Hide resolved
@matheus23
Copy link
Member Author

Ok, should be good to go. Mind giving this another look @appcypher?

I don't really like the sed-based hacks in the rs-wnfs script, but it works. I think I want to do something that bypasses wasm-pack at some point, so we have more control over the generated package.json. But that'll be another PR.

Copy link
Member

@appcypher appcypher left a comment

Choose a reason for hiding this comment

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

Looks great! 🎉

@appcypher appcypher merged commit 4837cba into main Jul 27, 2022
@matheus23 matheus23 deleted the matheus23/wasm-expose-stuff branch July 28, 2022 13:09
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.

Return metadata for each entry returned from ls from JS side
3 participants