Fix issues caused by @shared tsconfig path
This commit is contained in:
parent
53ed83b701
commit
9390b164d8
8 changed files with 56 additions and 18 deletions
10
backend/register-tsconfig-prod-paths.js
Normal file
10
backend/register-tsconfig-prod-paths.js
Normal file
|
@ -0,0 +1,10 @@
|
|||
const path = require('path');
|
||||
const tsconfig = require('./tsconfig.json');
|
||||
const tsconfigPaths = require('tsconfig-paths');
|
||||
|
||||
// E.g. ./dist/backend
|
||||
const baseUrl = path.resolve(tsconfig.compilerOptions.outDir, path.basename(__dirname));
|
||||
tsconfigPaths.register({
|
||||
baseUrl,
|
||||
paths: tsconfig.compilerOptions.paths || [],
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue