Skip to content

Commit

Permalink
fix(ssr): imported image paths set wrong
Browse files Browse the repository at this point in the history
due to a difference in how our client and ssr webpack configs were set up

https://mozilla-hub.atlassian.net/browse/MP-1088
  • Loading branch information
LeoMcA committed Apr 23, 2024
1 parent 8763695 commit 1d0445d
Showing 1 changed file with 13 additions and 2 deletions.
15 changes: 13 additions & 2 deletions ssr/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,22 @@ const config = {
ref: true,
},
},
"file-loader?outputPath=/distimages/",
],
},
{
test: /\.(png|svg|jpg|gif)$/,
use: ["file-loader?outputPath=/distimages/"],
test: [/\.avif$/, /\.bmp$/, /\.gif$/, /\.jpe?g$/, /\.png$/],
type: "asset",
parser: {
dataUrlCondition: {
maxSize: 0,
},
},
generator: {
emit: false,
publicPath: "/",
filename: "static/media/[name].[hash][ext]",
},
},
{ test: /\.(css|scss)$/, loader: "ignore-loader" },
],
Expand Down

0 comments on commit 1d0445d

Please sign in to comment.