MCPcopy
hub / github.com/josdejong/mathjs / _toHTML

Method _toHTML

src/expression/node/FunctionNode.js:426–436  ·  view source on GitHub ↗

* Get HTML representation * @param {Object} options * @return {string} str

(options)

Source from the content-addressed store, hash-verified

424 * @return {string} str
425 */
426 _toHTML (options) {
427 const args = this.args.map(function (arg) {
428 return arg.toHTML(options)
429 })
430
431 // format the arguments like "add(2, 4.2)"
432 return '<span class="math-function">' + escape(this.fn) +
433 '</span><span class="math-paranthesis math-round-parenthesis">(</span>' +
434 args.join('<span class="math-separator">,</span>') +
435 '<span class="math-paranthesis math-round-parenthesis">)</span>'
436 }
437
438 /**
439 * Get LaTeX representation. (wrapper function)

Callers

nothing calls this directly

Calls 3

escapeFunction · 0.90
mapMethod · 0.65
toHTMLMethod · 0.65

Tested by

no test coverage detected