j++ is for incrementing,
j-- is for decrementing :
for(let i = 0; i < len; i++)
→here you read through your array - from the first item (i = 0) to the last item (i = len)
let curr = arr[i];
let j = i - 1;
while(arr[j] > curr){
arr[j+1] = arr[j];
j--
};
j++
arr[j] = curr;
→Let say you have a subarray arr[0..i]. here you go through your subarray, in the inverse order.
Each time than a item is higher than arr[i], it takes the value of its predecessor. It makes all the value shift from one rank to the right of the array. When the while loop stops, the item on position j in the array takes the value of current, by this operation you make sure that you have moved the arr[i] value inside the arr[0..i] subarray, making sure that items are sorted inside this subarray.
Just remember that an invariant in the upper for loop is that arr[0..i] is sorted. When you increment i and go through a new iteration inside your for loop with the subarray arr[0..i], the curr value can be anything, but the values arr[0..i-1] are sorted, so the nested while loop make sure that the curr value is inserted where it should.
for instance, let's take your array [8,10,222,36,5,0,0]
. with i = 4 :
curr = 36
arr[0..i] = [8,10,222,36]
#iteration of the while loop :
j=3: arr[j]=222>curr -> arr[0..i]=[8,10,222,222]
j=2: arr[j]=10<curr -> end of the while loop
(arr[j+1] = curr) -> arr[0..i] = [8,10,36,222]
arr[0..4] is sorted