In nodejs, I have an array that looks somewhat like this.
["var/sys/log","var/sys/log/image", "var/sys/.dawn/noon",
"var/sys/.sbs/rise", "var/sys/.iris/quell", "....." ]
The array index is around 50-70
Now I want to delete all the elements that contain a "." expect for the entries that contain .sbs.
Any help here would be great. I have been racking my head off.
Edit after comments
I have tried array.filter, array.splice(foo.indexOf('.'>-1). But it deletes everything including .sbs.
And if it has sbs in it, I shouldn't delete it
Runtime is Nodejs v8 and not a browser.