File tree Expand file tree Collapse file tree 1 file changed +0
-9
lines changed
Expand file tree Collapse file tree 1 file changed +0
-9
lines changed Original file line number Diff line number Diff line change 1- import { writeFileSync } from 'fs' ;
21import { Experimental , Field , Gadgets } from 'o1js' ;
32const { ZkFunction } = Experimental ;
43
@@ -40,14 +39,6 @@ ok = await proof.verify(verificationKeyRoundTrip(verificationKey));
4039
4140console . log ( 'verification key round trip ok?' , ok ) ;
4241
43- console . log ( 'writing proof to file...' ) ;
44- writeFileSync ( 'zkfunction-proof.json' , JSON . stringify ( proofRoundTrip ( proof ) . toJSON ( ) , null , 2 ) ) ;
45-
46- console . log ( 'writing verification key to file...' ) ;
47- writeFileSync (
48- 'zkfunction-verification-key.data' ,
49- verificationKeyRoundTrip ( verificationKey ) . toString ( )
50- ) ;
5142function proofRoundTrip ( proof : Experimental . KimchiProof ) : Experimental . KimchiProof {
5243 let json = proof . toJSON ( ) ;
5344 console . log ( 'proof json:' , {
You can’t perform that action at this time.
0 commit comments