vendredi 24 janvier 2020

Remove empty items from my array and remove selected item when checkbox checked in react

const [person, setPerson] = useState(
        {
            name: "",
            age: "",
            school: "",
            address: "",
            telephone: "",

        }
    );

I want to remove the (telephone) when checkbox checked and also want to remove empty values from my array and thing is if any value is empty I wanna remove entire -> (telephone: "") from my array




Aucun commentaire:

Enregistrer un commentaire