API / @aionbuilders/nabu

EditorOptions

Type Stability: stable

Options of the editor factories: every NabuInit option (files, placeholders, snapshot, keymap, tab, lang…, forwarded to Nabu) plus the preset the factory starts from. extensions are appended to the preset's.

  • preset: base extensions (default: FullPreset, or the preset of the named factory).
  • tab: default by preset: Minimal / Text 'focus', Document / Full 'stay', a custom preset array 'focus'.

Related guide: Presets →

Definition

TypeScript
import type { EditorOptions } from '@aionbuilders/nabu';
TypeScript
type EditorOptions = Omit<NabuInit, 'extensions'> & { extensions?: Extension[]; preset?: Extension[] }

Combined with Omit<NabuInit, 'extensions'>

Properties

Properties of EditorOptions
PropertyTypeDescription
extensionsoptionalExtension[]n/a
presetoptionalExtension[]n/a

Source: src/lib/presets.js:61