mirror of
https://github.com/LukeHagar/sveltekit-og.git
synced 2025-12-09 04:21:44 +00:00
Basic Docs and publish.yml changes for pnpm v
This commit is contained in:
@@ -34,16 +34,16 @@ const ImageResponse = async (htmlTemplate: string, optionsByUser: ImageResponseO
|
||||
|
||||
if (!initialized) {
|
||||
await initSvgToPng();
|
||||
initialized = true
|
||||
initialized = true;
|
||||
}
|
||||
|
||||
const defaultConfig: ConvertOptions = {
|
||||
width: options.width, // optional
|
||||
height: options.height, // optional
|
||||
height: options.height // optional
|
||||
};
|
||||
|
||||
if (Object.hasOwn(options, 'backgroundColor')) {
|
||||
defaultConfig.backgroundColor = options.backgroundColor
|
||||
defaultConfig.backgroundColor = options.backgroundColor;
|
||||
}
|
||||
|
||||
const png = await svg2png(svg, defaultConfig);
|
||||
|
||||
Reference in New Issue
Block a user