Vector2.normalize()

Reduce the vector to a unit vector of length 1

Parameters

None

Return value

Vector2

The vector with its new values

Usage

import {Vector2} from '@lcluber/type6js';

let vector = new Vector2(2,2);
vector.normalize();