I am a bit new to react-static, so bear with me.
In development and when statically generated, refreshing a page when on a route that is used as such " /page/edit/:id" will change root reference of image assets.
My routing:
<Provider store={store}>
<PersistGate loading={null} persistor={persistor}>
<Root>
<header className="App-header">
<Navbar />
</header>
<div className="content">
<Router>
<Landing path="/" />
<Page1 key="page1" path="/page1" />
<Page1Edit key="page1-edit" path="/page1/edit/:id" />
<NotFound default />
</Router>
</div>
</Root>
</PersistGate>
</Provider>
Refreshing the root page has no affect on the issue, but when in the edit component, if a refresh or sometimes a hotload hits I lose all image asset references, which re-assign to the root of the component itself. For example, when working, the navbar logo is
img/logo.jpg
however when refreshed in the edit component the asset rewrites to
/edit/img/logo.jpg