modules/vector/vector.js
function sanitizeParameters (definition) {
    let scalar;
    try {
        // eslint-disable-next-line no-use-before-define
        const vector = Vector.from(definition);
        scalar = vector.getDelta();
    }
    catch (e) {
        scalar = definition.getDelta ? definition.getDelta() : definition;
    }
    return scalar;
}
function sanitizeParameters (definition) {
    let scalar;
    try {
        // eslint-disable-next-line no-use-before-define
        const vector = Vector.from(definition);
        scalar = vector.getDelta();
    }
    catch (e) {
        scalar = definition.getDelta ? definition.getDelta() : definition;
    }
    return scalar;
}
function sanitizeParameters ( definition ) { let scalar ; try { // eslint-disable-next-line no-use-before-define const vector = Vector . from ( definition ) ; scalar = vector . getDelta ( ) ; } catch ( e ) { scalar = definition . getDelta ? definition . getDelta ( ) : definition ; } return scalar ; }
Accept all kind of type and return only Number or Position
@param {VectorDefinition|PositionDefinition|Number} definition - Value definition
@return {Position|Number}
Accept all kind of type and return only Number or Position