I can only make sense of this question if the area of the square is x². The side of the square is 2x+2.
The area is (2x+2)²=x², so (2x+2)²-x²=0, (2x+2-x)(2x+2+x)=(x+2)(3x+2)=0.
So x=-2 or -⅔. The side length is therefore 2x+2=-2 or -4/3+2=⅔. The side length can’t be negative so x=-⅔, making the side length ⅔.