Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ConfigWithDefaults

Configurable object with defaults.

Hierarchy

  • ConfigWithDefaults

Index

Constructors

Properties

Methods

Constructors

constructor

  • Create a new config with defaults.

    Parameters

    Returns ConfigWithDefaults

Properties

Private _classData

_classData: any

Get data from the Section with our classname, if available.

Notes

If we have no classname, get all of the data in the Section

Private _className

_className: any

Private _defaults

_defaults: any

Private _section

_section: any

Methods

get

  • get(key: string): JSONValue
  • Get data from the config section or fall back to defaults.

    Parameters

    • key: string

    Returns JSONValue

set

  • set(key: string, value: JSONValue): Promise<JSONValue>
  • Set a config value.

    Notes

    Uses the Jupyter Notebook API.

    The promise is fulfilled on a valid response and rejected otherwise.

    Sends the update to the server, and changes our local copy of the data immediately.

    Parameters

    • key: string
    • value: JSONValue

    Returns Promise<JSONValue>

Generated using TypeDoc