Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

nx.option

nx.option.set(name, value, opts)

nx.option.set(name, value, opts) [alias nvim_set_option_value]: set an option in the scope its name implies. A window-local option (number/relativenumber) — or any option with an explicit opts.win — routes through nx.wo (the targeted window, else the current one); otherwise it routes through nx.bo (opts.buf, else the current buffer). The wired options reach the core; everything else lands in the observable per-scope store. (The scoped tables nx.o / nx.bo / nx.wo are the primary option API; this is the by-name funnel plugins reach for.)

Defined in state.lua.

nx.option.get(name, opts)

nx.option.get(name, opts) [alias nvim_get_option_value]: read an option from the scope its name implies (see nx.option.set), so a wired option reflects the core’s current value (default until set).

Defined in state.lua.