score:0

Accepted answer

the error message says onclick prop doesn't accept strings, only functions. you can update your onclick, just pass a function and check the row.values.status in there:

<link
  onclick={(e) => {
    if (row.values.status == 'ok') {
      e.preventdefault();
    } else {
      // do something else if `status` is not `ok`
    }
  }}
>
  action
</link>;

score:0

you are passing a string to onclick. you should declare a new onclick function and pass it on onclick attribute like below.

const onclick= (e) => {

if (row.values.status == "ok"){
e.preventdefault();}
}

onclick={onclick}
            

Related Query

More Query from same tag