Files
Joshua Castle 793aefd381 Resvg dynamic import
Signed-off-by: Joshua Castle <26531652+Kas-tle@users.noreply.github.com>
2024-03-24 15:06:29 -07:00

22 lines
599 B
TypeScript

import React from 'react';
import { type SatoriOptions } from 'satori';
export type ImageGeneratorOptions = SatoriOptions;
export type ImageGeneratorResult = {
url: string;
relativePath: string;
absolutePath: string;
};
export declare class ImageGenerator {
private args;
private satori;
private cache;
private outDir;
constructor(args: {
dir: string;
websiteUrl: string;
websiteOutDir: string;
});
init: () => Promise<void>;
generate: (element: React.ReactNode, options: ImageGeneratorOptions) => Promise<ImageGeneratorResult>;
}