Open abhijithvijayan opened 2 years ago
If you wanna add SVG or CSS into component as a module, just need some changement. Create a custom.d.ts file in root directory.
declare module '*.svg' {
import * as React from 'react';
export const ReactComponent: React.FunctionComponent<
React.SVGProps<SVGSVGElement>
>;
const src: string;
export default src;
}
declare module '*.css'
declare module '*.scss'
adjusting webpack config like
will add support for css modules so that
will work fine