Skip to content

Commit

Permalink
Change webpack configs to mjs
Browse files Browse the repository at this point in the history
For some reason node insists on loading them as commonjs despite
"type": "module" in package.json. This leads to import errors
in node 23.

Issue #234
  • Loading branch information
qu1ck committed Nov 1, 2024
1 parent 5c03fb4 commit cf10a86
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
"tauri-dev": "tauri dev",
"build": "tauri build",
"build-bin": "tauri build -b none",
"webpack-serve": "webpack serve --config webpack.dev.js",
"webpack-dev": "webpack --config webpack.dev.js",
"webpack-prod": "webpack --config webpack.prod.js",
"webpack-serve": "webpack serve --config webpack.dev.mjs",
"webpack-dev": "webpack --config webpack.dev.mjs",
"webpack-prod": "webpack --config webpack.prod.mjs",
"info": "tauri info",
"react-devtools": "npx react-devtools"
},
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion webpack.dev.js → webpack.dev.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
*/

import { merge } from "webpack-merge";
import common from "./webpack.common.js";
import common from "./webpack.common.mjs";

export default merge(common("development"), {
devtool: "source-map",
Expand Down
2 changes: 1 addition & 1 deletion webpack.prod.js → webpack.prod.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
*/

import { merge } from "webpack-merge";
import common, { __dirname } from "./webpack.common.js";
import common, { __dirname } from "./webpack.common.mjs";
import path from "path";
import { BundleAnalyzerPlugin } from "webpack-bundle-analyzer";

Expand Down

0 comments on commit cf10a86

Please sign in to comment.