Skip to content

Commit

Permalink
feat: add svgr/webpack
Browse files Browse the repository at this point in the history
  • Loading branch information
Max-Mogilski committed Nov 10, 2023
1 parent 6237215 commit bb05f8b
Show file tree
Hide file tree
Showing 4 changed files with 302 additions and 9 deletions.
7 changes: 7 additions & 0 deletions next.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,13 @@ const config = withPlugins(
},
],
},
webpack: (config) => {
config.module.rules.push({
test: /\.svg$/i,
use: ["@svgr/webpack"],
})
return config
},
})
)

Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@
"@storybook/react": "^7.4.6",
"@storybook/test-runner": "^0.13.0",
"@storybook/testing-library": "^0.1.0",
"@svgr/webpack": "^8.1.0",
"@testing-library/jest-dom": "^5.16.5",
"@testing-library/react": "^14.0.0",
"@total-typescript/ts-reset": "^0.5.0",
Expand Down
8 changes: 4 additions & 4 deletions src/components/Footer/Footer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,16 +39,16 @@ export async function Footer({ footer, logoUrl }: FooterProps) {
<nav className="flex flex-col gap-10 md:gap-7">
<div className="flex gap-5">
<a href={twitterLink ?? ""} aria-label="Twitter" target="_blank" rel="noreferrer">
<Image alt="X icon" src={XIcon} width={20} height={20} />
<XIcon />
</a>
<a href={facebookLink ?? ""} aria-label="Facebook" target="_blank" rel="noreferrer">
<Image alt="Facebook icon" src={FacebookIcon} width={20} height={20} />
<FacebookIcon />
</a>
<a href={instagramLink ?? ""} aria-label="Instagram" target="_blank" rel="noreferrer">
<Image alt="Instagram icon" src={InstagramIcon} width={20} height={20} />
<InstagramIcon />
</a>
<a href={youtubeLink ?? ""} aria-label="Youtube" target="_blank" rel="noreferrer">
<Image alt="Youtube icon" src={YoutubeIcon} width={20} height={20} />
<YoutubeIcon />
</a>
</div>
<ul className="grid grid-cols-3 gap-x-10 gap-y-7 text-sm font-semibold md:gap-x-20">
Expand Down
Loading

0 comments on commit bb05f8b

Please sign in to comment.