taglib-wasm
Version:
TagLib-Wasm is the universal tagging library for TypeScript/JavaScript platforms: Browsers, Node.js, Deno, Bun, Cloudflare Workers, and Electron apps
32 lines (31 loc) • 931 B
JavaScript
var __defProp = Object.defineProperty;
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
const SUPPORTED_FORMATS = [
"MP3",
"MP4",
"M4A",
"FLAC",
"OGG",
"WAV",
"MKA"
];
class TagLibError extends Error {
/**
* Creates a new TagLibError
* @param code - Error code for programmatic handling
* @param message - Human-readable error message
* @param details - Additional context about the error
*/
constructor(code, message, details) {
super(message);
__publicField(this, "code", code);
__publicField(this, "details", details);
this.name = "TagLibError";
Object.setPrototypeOf(this, TagLibError.prototype);
}
}
export {
SUPPORTED_FORMATS,
TagLibError
};