• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

visgl / loaders.gl / 24907303489

24 Apr 2026 07:12PM UTC coverage: 59.423% (+0.09%) from 59.334%
24907303489

push

github

web-flow
feat: Dynamic import loaders (#3405)

11252 of 20783 branches covered (54.14%)

Branch coverage included in aggregate %.

1164 of 1518 new or added lines in 244 files covered. (76.68%)

41 existing lines in 18 files now uncovered.

23432 of 37585 relevant lines covered (62.34%)

16317.58 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/modules/obj/src/obj-arrow-loader-with-parser.ts
1
// loaders.gl
2
// SPDX-License-Identifier: MIT
3
// Copyright (c) vis.gl contributors
4

5
import type {LoaderWithParser} from '@loaders.gl/loader-utils';
6
import type {ArrowTable} from '@loaders.gl/schema';
7

8
import {OBJLoaderOptions} from './obj-loader';
9
import {convertMeshToTable} from '@loaders.gl/schema-utils';
10
import {parseOBJ} from './lib/parse-obj';
11
import {OBJArrowLoader as OBJArrowLoaderMetadata} from './obj-arrow-loader';
12

13
const {preload: _OBJArrowLoaderPreload, ...OBJArrowLoaderMetadataWithoutPreload} =
NEW
14
  OBJArrowLoaderMetadata;
×
15

16
/**
17
 * Worker loader for OBJ - Point Cloud Data
18
 */
NEW
19
export const OBJArrowLoaderWithParser = {
×
20
  ...OBJArrowLoaderMetadataWithoutPreload,
21
  parse: async (arrayBuffer: ArrayBuffer) => {
NEW
22
    const text = new TextDecoder().decode(arrayBuffer);
×
NEW
23
    const mesh = parseOBJ(text);
×
NEW
24
    const arrowTable = convertMeshToTable(mesh, 'arrow-table');
×
NEW
25
    return arrowTable;
×
26
  }
27
} as const satisfies LoaderWithParser<ArrowTable, never, OBJLoaderOptions>;
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc