From cca763ad6c3117a88cb3328f284424be8ad59a02 Mon Sep 17 00:00:00 2001 From: armfazh Date: Tue, 18 Jan 2022 12:31:35 -0600 Subject: [PATCH] Resolve path correctly. --- webpack.config.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/webpack.config.js b/webpack.config.js index 14422530..56758eb3 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -2,12 +2,13 @@ import CopyWebpackPlugin from 'copy-webpack-plugin'; import HtmlWebpackPlugin from 'html-webpack-plugin'; import MiniCssExtractPlugin from 'mini-css-extract-plugin'; import TsconfigPathsPlugin from 'tsconfig-paths-webpack-plugin'; +import { fileURLToPath } from 'url'; import path from 'path'; // import buffer from "buffer"; // import streamBrowserify from "stream-browserify"; -const __dirname = path.dirname(new URL(import.meta.url).pathname); +const __dirname = path.dirname(fileURLToPath(import.meta.url)); const tsloader = { test: /\.tsx?$/,