Skip to content

Commit 3024773

Browse files
committed
fix standalone build
1 parent b0ecd0e commit 3024773

File tree

4 files changed

+4
-6
lines changed

4 files changed

+4
-6
lines changed

web/jest.config.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
2-
31
import type { Config } from 'jest';
42

53
const config: Config = {

web/moduleMapper/dummy.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { k8sModels } from './k8s-models';
66
// This dummy file is used to resolve @Console imports from @openshift-console for JEST / Standalone
77
// You can add any exports needed here
88
// Check "moduleNameMapper" in package.json for jest
9-
// and "NormalModuleReplacementPlugin" in webpack.standalone.ts
9+
// and "NormalModuleReplacementPlugin" in webpack.standalone.js
1010
export class Dummy extends Error {
1111
constructor() {
1212
super('Dummy file for exports');

web/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@
66
"clean": "rm -rf ./dist",
77
"build": "npm run clean && NODE_ENV=production npm run ts-node ./node_modules/.bin/webpack",
88
"build:dev": "npm run clean && npm run ts-node ./node_modules/.bin/webpack",
9-
"build:standalone": "npm run clean && webpack --config webpack.standalone.ts",
9+
"build:standalone": "npm run clean && webpack --config webpack.standalone.js",
1010
"start": "npm run ts-node-transpile ./node_modules/.bin/webpack serve",
11-
"start:standalone": "webpack serve --config webpack.standalone.ts",
11+
"start:standalone": "webpack serve --config webpack.standalone.js",
1212
"serve": "npx http-server ./dist -p 9001 -c-1 --cors $SERVER_OPTS",
1313
"i18n": "i18next \"src/**/*.{js,jsx,ts,tsx}\" [-oc] -c i18next-parser.config.js",
1414
"ts-node": "ts-node -O '{\"module\":\"commonjs\"}'",

web/webpack.standalone.ts renamed to web/webpack.standalone.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ module.exports = {
7777
new webpack.NormalModuleReplacementPlugin(
7878
/dynamic-plugin-sdk/,
7979
// eslint-disable-next-line @typescript-eslint/no-explicit-any
80-
function (resource: any) {
80+
function (resource) {
8181
resource.request = path.resolve(__dirname, "moduleMapper/dummy");
8282
}
8383
),

0 commit comments

Comments
 (0)