learn-content-engine - v0.34.0
    Preparing search index...

    Function evaluateExpression

    • Evaluate a computed variable's expression with values for its names (engine#220): the grammar the validator checks (E-VAR-EXPR), parsed by the same parser. Returns the IEEE result, so a division by zero gives Infinity or NaN rather than an exception. Throws when the expression does not parse (the message names the parse error, as E-VAR-EXPR does) or uses a name without a value.

      Parameters

      • expression: string
      • values: Readonly<Record<string, number>>

      Returns number