Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SVG image not import in React native #2261

Open
wolfxpertlab opened this issue Apr 20, 2024 · 0 comments
Open

SVG image not import in React native #2261

wolfxpertlab opened this issue Apr 20, 2024 · 0 comments

Comments

@wolfxpertlab
Copy link

wolfxpertlab commented Apr 20, 2024

Screenshot 2024-04-20 at 10 16 14 AM

My All svg image not show path that show error is

Cannot find module '../assets/svg/dashboardcart.svg' or its corresponding type declarations.

how can I solved it please help when I think that show error after installing firebase app and firestore before work better without install firebase

my declaration.d.ts file is:

declare module "*.svg" {
import React = require("react");
const ReactComponent: React.FC<React.SVGProps>;
export default ReactComponent;
}

my tsconfige file is:

{
"compilerOptions": {
"jsx": "react-jsx",
"lib": ["DOM", "ES2022"],
"moduleResolution": "node",
"target": "ES2022"
},
"include": ["src/types/declarations.d.ts","declarations.d.ts"],
"files": ["declarations.d.ts"],
"extends": "@react-native/typescript-config/tsconfig.json"
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant