80e74e9Add instrument/: the recorder behind the track-render interfaceJeremy Magland 1// The shipped MATLAB sources, loaded from ../matlab at build time. Browser
2// only (import.meta.glob is a Vite feature); node tests read the same files
3// through fs instead.
4import type { MFile } from './types.ts';
6const modules = import.meta.glob('../matlab/*.m', {
7 eager: true,
8 query: '?raw',
9 import: 'default',
10}) as Record<string, string>;
12export const DEFAULT_MFILES: MFile[] = Object.entries(modules)
13 .map(([path, source]) => ({ name: path.split('/').pop()!, source }))
14 .sort((a, b) => a.name.localeCompare(b.name));