How do I stop the current loop from executing the next loop?

      for (let p = 0; p < linkOri.length; pPP) {
                console.log(checkSetFalse.has(linkOri[p].source.group));
                console.log(checkSetFalse.has(linkOri[p].target.group));
                if (checkSetFalse.has(linkOri[p].source.group)
                  || checkSetFalse.has(linkOri[p].target.group)) {
                  break;
                }
                console.log("1111111111111");
                LinksObj.push(linkOri[p]);
              }

how to make LinksObj.push (Origin [p]) when the if condition does not hold; if you go here, it seems that the break loop has stopped at once?

Nov.01,2021

break-> continue


  Continue  

Menu