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: Minimal in-browser compatibility for the crate #149

Merged
merged 8 commits into from
Aug 27, 2024

Conversation

CPerezz
Copy link
Member

@CPerezz CPerezz commented Aug 21, 2024

This changes the associated type Params of the XXXFCircuit to use
the newly created PathOrBin type.

This allows the user of the lib to directly send the binary of the files
already read or instead, provide a path to it and let sonobe do the
work.

With this, Circom and Noir frontends should be already usable from the browser if we allow
JS to take care of reading the .wasm and .r1cs files.

This currently depends on:

This changes the associated type `Params` of the `CircomFCircuit` to use
the newly created `PathOrBin` type.

This allows the user of the lib to directly send the binary of the files
already read or instead, provide a path to it and let `sonobe` do the
work.

With this, Circom should be already usable from the browser if we allow
JS to take care of reading the `.wasm` and `.r1cs` files.
@CPerezz
Copy link
Member Author

CPerezz commented Aug 21, 2024

Submitted 3e2f8fc

Will work on the top of the rev for the time being. But not merge until we have it all working and merged.

This commit temporarilly stands on top of
dmpierre/arkworks_backend#1 referenced as `rev`.

This changes the associated type `Params` of the `CircomFCircuit` to use
the newly created `PathOrBin` type.

This allows the user of the lib to directly send the binary of the files
already read or instead, provide a path to it and let `sonobe` do the
work.

With this, Noir should be already usable from the browser if we allow
JS to take care of reading the `circuit.json` files
@CPerezz CPerezz marked this pull request as ready for review August 21, 2024 22:41
@CPerezz
Copy link
Member Author

CPerezz commented Aug 21, 2024

This is awaiting feedback from @czhang2718 and @janabel to see if with this is feasible and decently OK to use the crate compiled to WASM from the browser.

@CPerezz CPerezz requested review from dmpierre and arnaucube and removed request for dmpierre August 23, 2024 11:03
@CPerezz
Copy link
Member Author

CPerezz commented Aug 23, 2024

Got confirmation 0XPARC team that WASM is working. So this is good to go!
Will update the dependencies to branch instead of rev.

Copy link
Collaborator

@dmpierre dmpierre left a comment

Choose a reason for hiding this comment

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

Nice work, excited for finally having wasm compilation!

@CPerezz CPerezz added this pull request to the merge queue Aug 27, 2024
Merged via the queue into main with commit 52de2d1 Aug 27, 2024
8 checks passed
@CPerezz CPerezz mentioned this pull request Aug 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants