querySelectorAll doesn’t return an array, it returns an object that is “array-ish”. We want an array. Array.prototype.slice will copy an array. And .call(listItems) will tell that function to use listItems as the context in which to perform that function.
Basically we are converting something that is not really an array into an array.