I was implementing SSR (Server side Rendering) in a CRA (Create React App) and for mapping of the static media files, like svg I used the following code snipet,