Skip to content

Commit

Permalink
fix: eslint, tests
Browse files Browse the repository at this point in the history
  • Loading branch information
QuiiBz committed Aug 31, 2024
1 parent 9d424cf commit 1512b85
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
2 changes: 1 addition & 1 deletion apps/dashboard/next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ const nextConfig = {
pathname: '/a/*',
},
]
},
}
}

module.exports = nextConfig
10 changes: 5 additions & 5 deletions apps/dashboard/src/lib/export.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ if (process.env.VITEST_POOL_ID) {
"node_modules/@resvg/resvg-wasm/index_bg.wasm",
),
);
} {
} else {
initWasmPromise = initWasm(
fetch("https://unpkg.com/@resvg/[email protected]/index_bg.wasm", {
cache: "no-store",
})
}),
);
}

Expand Down Expand Up @@ -77,9 +77,9 @@ export function elementsToReactElements(
props: {
style: isImage
? {
...createElementStyle(element),
...createImgElementStyle(element),
}
...createElementStyle(element),
...createImgElementStyle(element),
}
: createElementStyle(element),
...(isImage
? { src: dynamicText ? dynamicText : element.backgroundImage }
Expand Down
3 changes: 2 additions & 1 deletion apps/dashboard/src/lib/fonts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,8 @@ export async function loadFonts(elements: OGElement[]): Promise<FontData[]> {
const fontName = element.fontFamily.toLowerCase().replace(" ", "-");
const data = await fetch(
// @ts-expect-error -- wrong inference
`https://fonts.bunny.net/${fontName}/files/${fontName}-latin-${element.fontWeight}-normal.woff`, { cache: 'no-store' }
`https://fonts.bunny.net/${fontName}/files/${fontName}-latin-${element.fontWeight}-normal.woff`,
{ cache: "no-store" },
).then((response) => response.arrayBuffer());

const fontData: FontData = {
Expand Down

0 comments on commit 1512b85

Please sign in to comment.