catamphetamine / universal-webpack

Isomorphic Webpack: both on client and server

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Question] SSR Support for Files like png and svg

nsunga opened this issue · comments

Hello!

I've been looking for a tool with SSR support for files.

I was about to use webpack-isomorphic-tools but turns out its in legacy mode.

It solves the issue with server-side rendering images: https://github.com/catamphetamine/webpack-isomorphic-tools#a-simple-example

My question is does universal-webpack offer this solution as well? It wasnt clear to me in the documentation. So some guidance would be appreciated!

For some context, I'm looking for a tool compatible with Webpack 5

@catamphetamine So does that mean the server bundle - based on the webpack server configuration that got created - magically reads the bundled images that Webpack creates?

If so, i'll give it a try with Webpack 5's "asset/resource": https://webpack.js.org/guides/asset-modules/

and thank you for the response!