It really depends on your specific needs so we need more information (why is it a long process? what is the goal of this process?) for a good answer, but one very simple approach would be to create another array that where the index is id (assuming the id is unique).
var listItemsById = [];
for(var i=0;i<listItems.length;i++){
listItemsById[listItems[i].id] = listItems[i];
}
After this, you can quickly access any item by id using listItemsById while still preserving the original listItems (because the items in listItemsById are only references to the originals).
UPDATE: Since I see several people have suggested using .filter (or an equivalent), I think that one of the things that needs to be made clear, as
Andy pointed out, is that there are (at least) two ways you can consider the original code a "long process":
1. It takes you a (relatively) long time to write (or not very clear when looking)
If this is your concern, then .filter is a clean solution, but keep in mind that it is not faster to execute (it may, in fact, be slower than using a loop, but this is implementation-dependent). It will still internally use a loop of some sort and you would get the same result if you wrote your own function, for example:
function findById(items, id) {
for(var i=0; i<items.length; i++){
if (items[i].id==id){
return items[i];
}
}
}
// example call
var selectedDataEdit=JSON.stringify(findById(listItems, 5));
2. It takes a long time to execute
If this is the case, then you need to provide more information on the use. While the solution I initially provided would be faster, it's very general and may not be a good idea (or may not even be applicable) in your particular case.