Files
firecrawl__anydoc/node/dts-header.d.ts
tomsideguide 8f05b1a3db feat(node): reject with an Error carrying the error code
- `code` on the rejection names the ConvertError variant, so callers
  branch on it rather than on the message text
- napi fills `code` from the error's status, so the rejection is rebuilt
  in Task::reject, the one place with an Env to build a JS error with
- ConvertErrorCode reaches index.d.ts through a dts header file, which
  survives regeneration
2026-08-05 18:36:10 +01:00

21 lines
766 B
TypeScript

/* auto-generated by NAPI-RS */
/* eslint-disable */
/**
* `code` on the `Error` a failed conversion rejects with. Conversion fails
* only when no meaningful Markdown could be produced; producer quirks are
* recovered or skipped instead.
*/
export type ConvertErrorCode =
/** Unknown format, or one that cannot be converted (an image-only PDF). */
| 'unsupported'
/** Structurally unusable: no meaningful content could be extracted. */
| 'malformed'
/** Encrypted or password-protected. */
| 'encrypted'
/** Crossed a fixed safety limit (decompression, nesting, node count). */
| 'resourceLimit'
/** A part required for any meaningful output is absent. */
| 'missingPart'
/** The file could not be read, from `toMarkdown` only. */
| 'io'