JSFiddle - React, Tailwind, and code Playground

by helgatheviking

JavaScript

const terms = [];
const id = 2;

if ( ! terms.length ) {
  console.debug("needs default");
}

if ( terms.indexOf( id ) !== -1 ) {
	console.debug("found one");
}