1
0
mirror of https://github.com/mastodon/mastodon synced 2024-12-23 19:18:41 +09:00
mastodon/config/webpack/loaders/assets.js

13 lines
307 B
JavaScript
Raw Normal View History

const { env, publicPath } = require('../configuration.js');
module.exports = {
test: /\.(jpg|jpeg|png|gif|svg|eot|ttf|woff|woff2)$/i,
use: [{
loader: 'file-loader',
options: {
publicPath,
name: env.NODE_ENV === 'production' ? '[name]-[hash].[ext]' : '[name].[ext]',
},
}],
};