Open quanzhuo opened 2 years ago
@quanzhuo I have the same issue, any luck?
@quanzhuo I have the same issue, any luck?
My workaround: use two webpack config files: webpack.config.client.js
and webpack.config.server.js
Install concurrently
npm package as a dev-dependency, and add following scripts in package.json
"develop": "concurrently \"npm run dev-client\" \"npm run dev-server\"",
"dev-client": "webpack --mode development --watch --config webpack.config.client.js",
"dev-server": "webpack --mode development --watch --config webpack.config.server.js",
Description
I have a vscode extension project. The project contains two complete separate apps, one for language client, the other for language server. The project structure is as follows:
The project is structured using tsc project reference. I want webpack to bundle my project into two separate js file: client.js and server.js so I add two entries in webpack config file. but ts-loader output an error:
NOTE: If I put only one entry in entry field, (either client or server), everything is fine
my webpack.config.js file content:
the root tsconfig.json file:
tsconfig.base.json:
client/tsconfig.json
server/tsconfig.json
Any suggestion appreciated.