tanem / react-svg

:art: A React component that injects SVG into the DOM.

Home Page:https://npm.im/react-svg

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

SVG URL EXTERNAL, How Can I mock!?

Bernardoow opened this issue · comments

Hey !!

I'm using this lib. My svg url is external and I'm doing a request when I'm running test.

Has a tutorial with information how I can mock this?

Hey there. This library uses nock to mock the SVG requests. If you take a look at the test files you'll be able to see how it's used, e.g. here.

Ok thank you @tanem !!!