I'm trying to pass a string[] from node.js to solidity function:
function test(string[] memory options) public {}
like this way:
const options = ["a","b","c"]
const contract = this.getContract();
const testFunc = contract.functions['test'];
await testFunc(options);
but got the error: invalid value for array;
Solidity pragma:
pragma solidity 0.6.5; pragma experimental ABIEncoderV2;
Also, if I call a contract from Etherscan with the same value it works