options.d.ts 1.3 KB

1234567891011121314151617181920212223242526
  1. export declare type ImportFromSource = {
  2. from: string;
  3. type?: string;
  4. } | string;
  5. export declare type ImportCustomProperties = {
  6. customProperties?: Record<string, string>;
  7. 'custom-properties'?: Record<string, string>;
  8. };
  9. export declare type ImportAsFunction = () => ImportFromSource | ImportCustomProperties;
  10. export declare type ImportAsPromise = Promise<ImportFromSource | ImportCustomProperties>;
  11. export declare type ImportAsFunctionPromise = () => Promise<ImportFromSource | ImportCustomProperties>;
  12. export declare type ImportOptions = ImportFromSource | ImportCustomProperties | ImportAsFunction | ImportAsPromise | ImportAsFunctionPromise;
  13. export declare type ExportJSONFunction = (customProperties?: Record<string, string>) => Record<string, string>;
  14. export declare type ExportToSource = {
  15. to: string;
  16. type?: string;
  17. toJSON: ExportJSONFunction;
  18. } | string;
  19. export declare type ExportCustomProperties = {
  20. customProperties?: Record<string, string>;
  21. 'custom-properties'?: Record<string, string>;
  22. toJSON: ExportJSONFunction;
  23. };
  24. export declare type ExportAsFunction = (ExportCustomProperties: any) => void;
  25. export declare type ExportAsFunctionPromise = (ExportCustomProperties: any) => Promise<void>;
  26. export declare type ExportOptions = ExportToSource | ExportCustomProperties | ExportAsFunction | ExportAsFunctionPromise;