I am developing a website using React and I use Webpack to bundle the files. I use several .png images on the site but I have a problem with one of these since when I try to create the package, this image is not loaded and in the Google Chrome console I read something like this:
GET http://localhost/bundle/data:image/png;base64,iVBOR...AAAAASUVORK5CYII= 414 (Request-URI Too Long)
This is my webpack.config.js:
const webpackConfig = env => {
    return {
        mode: env === "development" ? "development" : "production",
        entry: ["./src/index.tsx"],
        output: {
            filename: "bundle.js",
            path: path.join(__dirname, "server/public/bundle/")
        },
        resolve: {
            // Add '.ts' and '.tsx' as resolvable extensions.
            extensions: ['.ts', '.tsx', '.js', '.jsx']
        },
        module: {
            rules: [
                {
                    test: /\.(jsx|tsx|js|ts)$/,
                    loader: "ts-loader",
                    options: {
                        transpileOnly: true,
                         compilerOptions: {
                            target: env === "development" ? "ES6" : "es5"
                        }
                    },
                },
                {
                    test: /\.css$/,
                    use: ['style-loader', 'css-loader']
                },
                {
                    test: /\.(png|woff|woff2|eot|ttf|svg)$/,
                    loader: 'url-loader?limit=100000'
                }
            ]
        },
    }
};
module.exports = env => webpackConfig(env);
By varying the limit used in url-loader?limit=100000 I noticed that under 30000 the image is displayed correctly but many other images do not work due an 404 errors.
How can I fix the problem?