7 lines
307 B
TypeScript
7 lines
307 B
TypeScript
import packages from 'virtual:bgm/packages';
|
|
import type { SerializedPackage } from '@tts/bgm';
|
|
|
|
/** Look up a bgm package by id from the `virtual:bgm/packages` module. */
|
|
export function findPackage(id: string | undefined): SerializedPackage | undefined {
|
|
return packages.find((p) => p.meta.id === id);
|
|
} |