JaimeGensler / thyseus

An archetypal Entity Component System, built entirely in Typescript
MIT License
74 stars 3 forks source link

[FEAT] `Maybe<T>` in queries #61

Closed JaimeGensler closed 9 months ago

JaimeGensler commented 11 months ago

Describe the problem this feature solves

Optionally query for components if they're present, yield undefined if not.

We could probably just provide an empty array for columns that aren't present in the matched table and rely on OoB access to return undefined