Alpha: this compiler is under active development and updates will break your projects. Not recommended for real use yet.
Skip to content

twine / registerItem

Function: registerItem() โ€‹

registerItem<T>(name, item): T

Defined in: twine/src/item/registry.ts:17

Registers item under name for the give commands, and returns it unchanged.

Type Parameters โ€‹

T โ€‹

T extends ItemValue

Parameters โ€‹

name โ€‹

string

item โ€‹

T

Returns โ€‹

T

Released under the MIT License ยท Credits
These docs were written with AI; the layout and every page have been reviewed by a human.