Luxar Viewer API Documentation - v2026.9.22
    Preparing search index...

    Module data/loaders/once-init

    One-shot async initializer with retry-on-failure semantics.

    Each spatial-index loader wraps its initialize() method in the same guard: cache the in-flight promise so concurrent callers all await the same work, but null it back out on rejection so the next caller can retry from scratch. That pattern was duplicated four times across the three loaders. This helper centralizes it.

    private _onceInit = new OnceInit();

    async loadGSplats(...) {
    await this._onceInit.ensure(() => this.initialize());
    // ...
    }
    OnceInit