Skip to content

Commit

Permalink
chore: Add links to complete NoirJS app code to the guide (#3359)
Browse files Browse the repository at this point in the history
Co-authored-by: Tom French <15848336+TomAFrench@users.noreply.github.com>
  • Loading branch information
critesjosh and TomAFrench authored Oct 30, 2023
1 parent c3c169e commit a96d64d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion docs/docs/noir_js/getting_started/01_tiny_noir_app.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ keywords: [how to, guide, javascript, typescript, noir, barretenberg, zero-knowl

NoirJS works both on the browser and on the server, and works for both ESM and CJS module systems. In this page, we will learn how can we write a simple test and a simple web app to verify the standard Noir example.

You can find the complete app code for this guide [here](https://github.com/noir-lang/tiny-noirjs-app).

## Before we start

:::note
Expand Down Expand Up @@ -45,7 +47,7 @@ Go back to the previous folder and start a new project by running run `npm init`
We'll need two `npm` packages. These packages will provide us the methods we need to run and verify proofs:

```bash
npm i @noir-lang/backend_barretenberg@^0.17.0 @noir-lang/noir_js@^0.17.0
npm i @noir-lang/backend_barretenberg@^0.17.0 @noir-lang/noir_js@^0.17.0
```

To serve our page, we can use a build tool such as `vite`. Because we're gonna use some `wasm` files, we need to install a plugin as well. Run:
Expand Down Expand Up @@ -249,6 +251,8 @@ if (verification) display('logs', 'Verifying proof... ✅');

By saving, your app will refresh and here's our complete Tiny Noir App!

You can find the complete app code for this guide [here](https://github.com/noir-lang/tiny-noirjs-app).

## Further Reading

You can see how noirjs is used in a full stack Next.js hardhat application in the [noir-starter repo here](https://github.com/noir-lang/noir-starter/tree/main/next-hardhat). The example shows how to calculate a proof in the browser and verify it with a deployed Solidity verifier contract from noirjs.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ description: Learn about the cryptographic primitives regarding ECDSA over the s
keywords: [cryptographic primitives, Noir project, ecdsa, secp256k1, secp256r1, signatures]
---

import BlackBoxInfo from '../../../src/components/Notes/_blackbox.mdx';
import BlackBoxInfo from '@site/src/components/Notes/_blackbox.mdx';

Noir supports ECDSA signatures verification over the secp256k1 and secp256r1 curves.

Expand Down

0 comments on commit a96d64d

Please sign in to comment.