Skip to content

Commit 14d78da

Browse files
committed
style: resolve linting errors in webpack config files
1 parent 871ecb4 commit 14d78da

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

packages/client/webpack.config.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,8 @@ module.exports = composePlugins(withNx(), withWeb(), (config) => {
5050
vscode: 'commonjs vscode', // ignored because it doesn't exist
5151
};
5252

53+
config.output = config.output ?? {};
54+
5355
config.output.libraryTarget = 'commonjs2';
5456
// config.output.filename = 'extension.js';
5557

@@ -69,7 +71,9 @@ module.exports = composePlugins(withNx(), withWeb(), (config) => {
6971
extension: './src/extension.ts',
7072
};
7173

72-
config.output.devtoolModuleFilenameTemplate = function (info) {
74+
config.output.devtoolModuleFilenameTemplate = function (
75+
/** @type {{ absoluteResourcePath: string; }} */ info
76+
) {
7377
const rel = path.relative(process.cwd(), info.absoluteResourcePath);
7478
return `webpack:///./${rel}`;
7579
};

packages/server/webpack.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ module.exports = composePlugins(withNx(), withWeb(), (config) => {
5858
'tree-sitter-ccini': 'commonjs ../../tree-sitter-ccini',
5959
};
6060

61-
config.output = config.output || {};
61+
config.output = config.output ?? {};
6262

6363
config.output.libraryTarget = 'commonjs2';
6464
// config.output.filename = 'extension.js';

0 commit comments

Comments
 (0)