Skip to main content

constant

Function constant 

Source
pub fn constant(name: &str) -> Option<Value>
Expand description

A non-function member of the repl namespace, reachable via namespace_property IF the parent routes "repl" into stdlib::constant.

  • repl.REPLServer — the server class. node-js has no first-class exposed REPLServer constructor (the server object is produced by start()), so this is documented-only and returns None; use repl.start().
  • repl.writer — Node’s default output formatter (util.inspect). We expose it as the util.inspect builtin so repl.writer(value) formats identically to the REPL’s own result rendering.

Requires the parent to route "repl" into stdlib::constant.