From 323fb21e7e81815c8013a8a1b74f5656f9f8720e Mon Sep 17 00:00:00 2001 From: lizaklimova <132839549+lizaklimova@users.noreply.github.com> Date: Fri, 26 Jan 2024 18:20:43 +0200 Subject: [PATCH] added jpg type --- @types/custom.d.ts | 5 +++++ declarations.d.ts | 4 ---- tsconfig.json | 2 +- webpack.config.js | 7 ------- 4 files changed, 6 insertions(+), 12 deletions(-) delete mode 100644 declarations.d.ts diff --git a/@types/custom.d.ts b/@types/custom.d.ts index 976cf50..9c17307 100644 --- a/@types/custom.d.ts +++ b/@types/custom.d.ts @@ -7,3 +7,8 @@ declare module '*.png' { const content: any; export default content; } + +declare module '*.jpg' { + const content: any; + export default content; +} diff --git a/declarations.d.ts b/declarations.d.ts deleted file mode 100644 index a67551f..0000000 --- a/declarations.d.ts +++ /dev/null @@ -1,4 +0,0 @@ -declare module '*.jpg' { - const value: string; - export default value; -} diff --git a/tsconfig.json b/tsconfig.json index 73a90d7..0b11eae 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -17,5 +17,5 @@ "jsx": "react-jsx", "baseUrl": "./src" }, - "include": ["src", "@types", "declarations.d.ts"] + "include": ["src", "@types"] } diff --git a/webpack.config.js b/webpack.config.js index 6033b01..1f7ac17 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -16,13 +16,6 @@ module.exports = { use: 'ts-loader', exclude: /node_modules/, }, - { - test: /\.(jpg|jpeg)$/i, - type: 'asset/resource', - generator: { - filename: 'images/[name][ext]', - }, - }, ], }, };