We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8ff69f4 commit d49afedCopy full SHA for d49afed
1 file changed
src/index.ts
@@ -37,6 +37,9 @@ export default function vitePluginSvgr({
37
38
const filePath = id.replace(postfixRE, "");
39
const svgCode = await fs.promises.readFile(filePath, "utf8");
40
+ // `tsx` injects an import-interop helper here during tests, which adds
41
+ // an unreachable branch to coverage for these ESM-only modules.
42
+ /* c8 ignore next 2 */
43
const { transform: svgrTransform } = await import("@svgr/core");
44
const { default: jsx } = await import("@svgr/plugin-jsx");
45
const componentCode = await svgrTransform(svgCode, svgrOptions, {
0 commit comments