How to have inline assets working in production bundling?
See original GitHub issueI’ve tried several times to configure Webpack to be able to bundle inline assets, such as <img src="path/images/xyz.jpg" />
, however, the paths do not get updated within the dist
bundle and I don’t believe the assets
are there either.
Any ideas?
Issue Analytics
- State:
- Created 6 years ago
- Comments:7
Top Results From Across the Web
Bundle inlining - Parcel
Parcel includes several ways to inline the compiled contents of one bundle inside another bundle.
Read more >Production | webpack
In this guide, we'll dive into some of the best practices and utilities for building a production site or application.
Read more >How to Bundle a Simple Static Site Using Webpack - SitePoint
Add the following to app.js : require('./main.js');. And change the webpack config thus: entry: './src/js/app.js',. Run npm run build again to ...
Read more >Webpack 5 - how to bundle assets from an npm module
To get around this issue I have converted all images in myNpmModule to data URL's using the webpack asset module ("asset/inline").
Read more >JavaScript Bundling | Commerce Frontend Development
JavaScript bundling does not work unless the application is in production mode. Once in production mode, JavaScript bundling can only be ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Cool
loaders: ['file-loader?hash=sha512&digest=hex&name=[hash].[ext]', 'image-webpack-loader']
but then it might break the.styl
urlI noticed we could also leverage the
html-loader
to be able to require assets withinhtml
templates.