Answers for "how to check if true value in js"

0

check if javascript function is true

function example(){
  return true;
}

if(example()){ 
  console.log('hello');
}else{
  console.log('bye');
}

// result: 'hello'
Posted by: Guest on November-20-2019

Code answers related to "how to check if true value in js"

Code answers related to "Javascript"

Browse Popular Code Answers by Language