We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I want to use a different webpack loader for .css files (NOTE: Flow generates a webpack.generated.js that uses raw-loader for that).
.css
webpack.generated.js
raw-loader
This is what I have in webpack.config.js
webpack.config.js
module.exports = merge(flowDefaults, { module: { rules: [ { test: /\.css$/i, loader: "lit-css-loader" } ] } });
I want that to be sufficient to override the Flow defaults. With Flow 3.0.0.alpha7 it is not.
Investigation:
So the problem is that the merge appends new values to the other, try this:
module.exports = merge(flowDefaults, { module: { rules: [ { test: /\.css$/i, use: ['lit-css-loader'] } ] }, }); console.log(module.exports.module.rules);
then run webpack and you get
[ { test: /\.js$/, use: [ [BabelMultiTargetLoader] ] }, { test: /\.ts$/, use: [ [BabelMultiTargetLoader], 'awesome-typescript-loader' ] }, { test: /\.css$/i, use: [ 'raw-loader' ] }, { test: /\.css$/i, use: [ 'lit-css-loader' ] } ]
The text was updated successfully, but these errors were encountered:
Ref: https://github.com/vaadin-learning-center/crm-tutorial-typescript/blob/with-styling/webpack.config.js#L7-L13
Sorry, something went wrong.
Also consider priorities for vite.config.ts.
vite.config.ts
No branches or pull requests
I want to use a different webpack loader for
.css
files (NOTE: Flow generates awebpack.generated.js
that usesraw-loader
for that).This is what I have in
webpack.config.js
I want that to be sufficient to override the Flow defaults. With Flow 3.0.0.alpha7 it is not.
Investigation:
So the problem is that the merge appends new values to the other, try this:
then run webpack and you get
The text was updated successfully, but these errors were encountered: