Skip to content

Commit

Permalink
feature/2022-11-25-asktug-home: fix for import svg
Browse files Browse the repository at this point in the history
  • Loading branch information
cw1997 committed Feb 10, 2023
1 parent 13e4afd commit 9f4be46
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
9 changes: 9 additions & 0 deletions packages/site-components/env.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
import React, {FC} from "react";

declare module "*.svg" {
import { FC } from 'react'
const Icon: FC
export default Icon
}

// declare module "*.svg" {
// const content: React.FunctionComponent<React.SVGAttributes<SVGElement>>;
// export default content;
// }

declare module "*.png"
3 changes: 2 additions & 1 deletion packages/site-components/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,6 @@
"jsx": "react",
"allowSyntheticDefaultImports": true,
"resolveJsonModule": true,
}
},
"include": ["src/**/*", "env.d.ts"]
}

0 comments on commit 9f4be46

Please sign in to comment.