It will say that name and are undefined but I don't know why and how to fix it.
My code:
It will say that name and are undefined but I don't know why and how to fix it.
My code:
For further actions, you may consider blocking this person and/or reporting abuse
Join the DEV x Linode Hackathon 2022 and use your ingenuity and creativity to build using Linode.
β Join the Hackathon <-
Daniel Bemsen Akosu -
Sebastien Lorber -
Necati Γzmen -
Vincent Will -
Once suspended, grzesiekkozdroj will not be able to comment or publish posts until their suspension is removed.
Once unsuspended, grzesiekkozdroj will be able to comment and publish posts again.
Once unpublished, all posts by grzesiekkozdroj will become hidden and only accessible to themselves.
If grzesiekkozdroj is not suspended, they can still re-publish their posts from their dashboard.
Once unpublished, this post will become invisible to the public and only accessible to Grzesiek Kozdroj.
They can still re-publish the post if they are not suspended.
Thanks for keeping DEV Community π©βπ»π¨βπ» safe. Here is what you can do to flag grzesiekkozdroj:
Unflagging grzesiekkozdroj will restore default visibility to their posts.
Top comments (1)
const phoneExp = /\(?![0])|[0])[0-9](?[0-9])?[0-9]*$/;
const formValid = formErrors => {
let valid = true;
Object.values(formErrors).forEach(val => {
val.length > 0 && (valid = false);
});
}
class App extends React.Component {
constructor(props) {
super(props)
this.state={
nameInput: null,
phoneInput: null,
formErrors:{
nameInput:"",
phoneInput:""
}
}
}
handleSubmit = e =>{
e.preventDefault();
if(formValid(this.state.formErrors)){
console.log(
);--SUBMITTED--
--nameInput:${this.state.nameInput}
--phoneInput:${this.state.phoneInput}
}else{
console.log(
error
)}
}
}
document.addEventListener('DOMContentLoaded', function () {
ReactDOM.render(
,
document.getElementById('app')
);
});