Skip to content

Commit 777f460

Browse files
code-asherkylecarbs
authored andcommitted
Use options instead of separate tsconfig
Negates the need to duplicate the HappyPack config.
1 parent e7d7ff3 commit 777f460

3 files changed

Lines changed: 8 additions & 22 deletions

File tree

packages/server/src/server.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ export const createApp = (registerMiddleware?: (app: express.Application) => voi
3535
try {
3636
ws.send(data);
3737
} catch (error) {
38-
logger.error(error.message, field("error", error));
38+
logger.error(error.message);
3939
}
4040
},
4141
onClose: (cb): void => ws.addEventListener("close", () => cb()),

packages/web/tsconfig.json

Lines changed: 0 additions & 8 deletions
This file was deleted.

packages/web/webpack.common.config.js

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ const path = require("path");
22
const HtmlWebpackPlugin = require("html-webpack-plugin");
33
const { BundleAnalyzerPlugin } = require("webpack-bundle-analyzer");
44
const PreloadWebpackPlugin = require("preload-webpack-plugin");
5-
const HappyPack = require("happypack");
65
const root = path.resolve(__dirname, "..", "..");
76
const fills = path.join(root, "packages", "ide", "src", "fill");
87
const vsFills = path.join(root, "packages", "vscode", "src", "fill");
@@ -96,17 +95,12 @@ module.exports = merge({
9695
rel: "preload",
9796
as: "script",
9897
}),
99-
new HappyPack({
100-
id: "ts",
101-
threads: 2,
102-
loaders: [{
103-
path: "ts-loader",
104-
query: {
105-
happyPackMode: true,
106-
configFile: path.join(__dirname, "tsconfig.json"),
107-
},
108-
}],
109-
}),
11098
],
11199
target: "web",
112-
}, require(path.join(root, "scripts", "webpack.general.config.js"))());
100+
}, require(path.join(root, "scripts", "webpack.general.config.js"))({
101+
typescriptCompilerOptions: {
102+
"target": "es5",
103+
"lib": ["dom", "esnext"],
104+
"importHelpers": true,
105+
},
106+
}));

0 commit comments

Comments
 (0)