Skip to content

Commit

Permalink
trying to fix the lack of process
Browse files Browse the repository at this point in the history
but now the tests are like hanging in the browser? oh, maybe this is
something more global — the node tests seem to be having a moment too
  • Loading branch information
lawrence-forooghian committed Dec 14, 2023
1 parent 41c8956 commit 0ad9608
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 1 deletion.
16 changes: 16 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@
"path-browserify": "^1.0.1",
"playwright": "^1.39.0",
"prettier": "^2.8.8",
"process": "^0.11.10",
"react": ">=18.1.0",
"react-dom": ">=18.1.0",
"requirejs": "~2.1",
Expand Down
7 changes: 6 additions & 1 deletion webpack.config.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* eslint-disable @typescript-eslint/no-var-requires */
const path = require('path');
const { BannerPlugin } = require('webpack');
const { BannerPlugin, ProvidePlugin } = require('webpack');
const banner = require('./src/fragments/license');
const CopyPlugin = require('copy-webpack-plugin');
// This is needed for baseUrl to resolve correctly from tsconfig
Expand Down Expand Up @@ -218,6 +218,11 @@ function createMochaJUnitReporterConfigs() {
filename: 'browser.js',
library: 'MochaJUnitReporter',
},
plugins: [
new ProvidePlugin({
process: 'process/browser.js',
}),
],
resolve: {
fallback: {
// These are the modules suggested by Webpack, post v5-upgrade, to replace v4’s built-in shims.
Expand Down

0 comments on commit 0ad9608

Please sign in to comment.