Skip to content

API Reference / @gtkx/codegen / readGeneratedElements

Variable: readGeneratedElements

const readGeneratedElements: (jsxStoreDir) => GeneratedElement[]

Defined in: codegen/dist/store/jsx/generated-elements.d.ts:27

Reads the inventory of elements the @gtkx/jsx store binds, written into the store by codegen. Answers "what does this project's JSX layer cover" without loading the store, which resolves virtual: specifiers that only exist inside a Vite or Vitest build.

Parameters

jsxStoreDir

string

The jsx store directory, as given by resolveStore(projectRoot).jsx.storeDir.

Returns

GeneratedElement[]

Every bound element, sorted by GLib type name, or an empty array when the store has no inventory.

Released under the MPL-2.0 License.