Discuss / JavaScript / 可调控

可调控

Topic source
var pool=["Swift","ANSI C","DirectX"];
var root=document.getElementById("test-list");
var array=Array.from(root.children);
for(let i of array)  if(pool.indexOf(i.innerHTML)!=-1)  root.removeChild(i);

  • 1

Reply