electronmon
electronmon copied to clipboard
Cannot find module '@/src/xxx'
how to parse url like "@/src/xxx" in main process?
here is package script:
"start:main": "cross-env NODE_ENV=development electronmon -r ts-node/register/transpile-only ."
and here is part of tsconfig:
"baseUrl": "./",
"paths": { "@/*": ["./*"] }
but i got error "Cannot find module '@/src/xxx'"
I have tried to get this working and had little luck, this library looks as though it should help but it didn't work well with electronmon. In my case I think this is an issue with how ts config are shared across processes, and, how I have my repo setup for which I used electron-react-booilerplate.
https://www.npmjs.com/package/tsconfig-paths