rebased/app/soapbox/components/__mocks__/react-inlinesvg.tsx
marcin mikołajczak 81de0014d3 Change ESLint rules, lint
Signed-off-by: marcin mikołajczak <git@mkljczk.pl>
2023-02-16 00:12:02 +01:00

16 lines
329 B
TypeScript

import React from 'react';
interface IInlineSVG {
loader?: JSX.Element
}
const InlineSVG: React.FC<IInlineSVG> = ({ loader }): JSX.Element => {
if (loader) {
return loader;
} else {
throw 'You used react-inlinesvg without a loader! This will cause jumpy loading during render.';
}
};
export default InlineSVG;