Consider this move function which does not expect functionArguments or typeArguments
#[view]
public fun exist_message(): bool {
exists<Message>(get_board_obj_address())
}
We should be able to call it with Surf like that
surfClient.view.exist_message();
Instead, Surf requires to pass in empty functionArguments and typeArguments
surfClient.view.exist_message({
functionArguments: [],
typeArguments: [],
});
Can see the @aptos-labs/ts-sdk makes both arguments optional
https://github.com/aptos-labs/aptos-ts-sdk/blob/main/src/internal/view.ts#L17
https://github.com/aptos-labs/aptos-ts-sdk/blob/main/src/transactions/types.ts#L175-L179
Consider this move function which does not expect
functionArgumentsortypeArgumentsWe should be able to call it with Surf like that
Instead, Surf requires to pass in empty
functionArgumentsandtypeArgumentsCan see the
@aptos-labs/ts-sdkmakes both arguments optionalhttps://github.com/aptos-labs/aptos-ts-sdk/blob/main/src/internal/view.ts#L17
https://github.com/aptos-labs/aptos-ts-sdk/blob/main/src/transactions/types.ts#L175-L179