src/nodejs/jsdiagnostics_channel

  Source   Edit

Types

Channel = ref object of JsRoot
  hasSubscribers*: bool      ## https://nodejs.org/api/diagnostics_channel.html#diagnostics_channel_channel_hassubscribers
  
https://nodejs.org/api/diagnostics_channel.html#diagnostics_channel_class_channel   Source   Edit

Procs

func hasSubscribers(name: cstring): bool {.
    importjs: "diagnostics_channel.$1(#)", ...raises: [], tags: [].}
https://nodejs.org/api/diagnostics_channel.html#diagnostics_channel_diagnostics_channel_hassubscribers_name   Source   Edit
func importDiagnosticsChannel() {.importjs: "import * as diagnostics_channel from \'diagnostics_channel\'@",
                                  ...raises: [], tags: [].}
Alias for import * as module_name from 'module_name';. Must be called once before using the module   Source   Edit
func publish(self: Channel; message: auto): bool {.importjs: "#.$1(#)",
    ...raises: [], tags: [].}
https://nodejs.org/api/diagnostics_channel.html#diagnostics_channel_channel_publish_message   Source   Edit
func requireDiagnosticsChannel() {.importjs: "const diagnostics_channel = require(\'diagnostics_channel\')@",
                                   ...raises: [], tags: [].}
Alias for const module_name = require('module_name');. Must be called once before using the module   Source   Edit
func subscribe[T](self: Channel; onMessage: T) {.importjs: "#.$1(#)",
    ...raises: [], tags: [].}
https://nodejs.org/api/diagnostics_channel.html#diagnostics_channel_channel_subscribe_onmessage   Source   Edit
func unsubscribe[T](self: Channel; onMessage: T) {.importjs: "#.$1(#)",
    ...raises: [], tags: [].}
https://nodejs.org/api/diagnostics_channel.html#diagnostics_channel_channel_unsubscribe_onmessage   Source   Edit