Code challange help

I am writing a program that add the sum of squares of each digit in that number until the sum become one single integer. For example: 203 -> 13 -> 10 -> 1 -> 1

I have been figured out the first step but I am stuck to proceed to reach one single integer, Can anyone helps

function squareSum(numbers) {
     var numbers = Array.from(String(numbers), Number);
     var square_sum = [];

     for (let i = 0; i < numbers.length; i++) {
         square_sum.push(numbers[i] * numbers[i]);

     var SquareSum = 0

     for (let j = 0; j < square_sum.length; j++) {
         SquareSum = SquareSum + square_sum[j];
     return SquareSum;


easy mistake

// SquareSum = foo + bar

var SquareSum // = foo + bar

I’ve edited your post for readability. When you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.

See this post to find the backtick on your keyboard. The “preformatted text” tool in the editor (</>) will also add backticks around text.

Note: Backticks are not single quotes.