twig-html-loader
twig-html-loader copied to clipboard
Add webpack 5 support
https://webpack.js.org/blog/2020-10-10-webpack-5-release/
Hi @radiocity,
Any news on this?
I have test the loader with webpack@5 and it looks like it's working fine. However, raw-loader is now deprecated, so you may have to take a look at asset modules, see https://webpack.js.org/guides/asset-modules/.
Thanks for your feedback! :wink:
Adjusting the webpack configuration and drop raw-loader works fine, even with the current twig-html-loader version:
module.exports = () => ({
module: {
rules: [
{
test: /\.twig$/,
exclude: /node_modules/,
type: 'asset/source', // <-- with new asset-modules
use: [
{
loader: 'twig-html-loader',
options: {
...
As a side note, what about project 1.0.0 ?.. is it definitely closed? :thinking:
@xavierfoucrier, the project will develop as I find the strength to work on weekends :C
Hi @radiocity,
I totally understand what you mean :smile: No problem, feel free to give a feedback when you need to test something with webpack 5.
Cheers! :beers: