how to add or remove records from the array of objects in js code example Example: javascript pop object from array array.pop()