MCPcopy Create free account
hub / github.com/cortex-js/compute-engine / evaluateToJson

Function evaluateToJson

test/compute-engine/smoke.test.ts:30–32  ·  view source on GitHub ↗
(latex: string)

Source from the content-addressed store, hash-verified

28}
29
30function evaluateToJson(latex: string): Expression {
31 return engine.parse(latex).evaluate()?.toMathJson() ?? 'NULL';
32}
33
34function NToJson(latex: string): Expression {
35 // toMathJson() produces a sugared expression, unlike .json

Callers 1

smoke.test.tsFile · 0.85

Calls 3

toMathJsonMethod · 0.65
evaluateMethod · 0.65
parseMethod · 0.65

Tested by

no test coverage detected