While for 2) how do you instantiate and interact with the script? In the docs it states to use callScript and ScriptHelper, but not much documentation or usage for both libraries.:
Hi @p.s, within the scripts folder src/sway-api/scripts/TestScript.ts
How can we use const scriptBin = readFileSync(join(__dirname, './path/to/script-binary.bin')); to read the bytecode? I noticed that readFileSync seems to be depreciated.
Is there a way to get the ABI by file without copy and pasting the whole json?
Hi friends, for anyone who faced the following problems, it is because we need to interact with generated types. For those working with NextJS, do ensure u checkout this thread to fix your issues.
Update: Doesn’t Work for Vanilla NextJS (I.e. didn’t run the command pnpm create fuels)