We are using ethers.js for this particular example
ethers.js
Use signer.signMessage message from Signer class
signer.signMessage
Signer
const message = await generateMessage() const signer = new ethers.Wallet() const signature = await signer.signMessage(message) // OR const signature = await signer.signMessage(Buffer.from(message))
Last updated 1 year ago