manfredsteyer / module-federation-plugin-example

264 stars 182 forks source link

module not found error #36

Open JP-Jagadesan opened 1 year ago

JP-Jagadesan commented 1 year ago

I am using "@angular-architects/module-federation": "^14.3.14" version in angular application with a library named test and application named host. I used path mapping in angular tsconfig as below.

"paths": { "test/": [ "projects/test/", "dist/test" ] } i am trying to access a module like import { TestModule } from 'test/first'; in my app.module and trying to render the library component in app.html.

Error: Module not found: Error: Can't resolve 'test/*' in 'E:\mfe\projects\host\src\app'.

image

I encountered this error only after introducing the webpack file. I suspect the webpack is not resolving the my path alias

JP-Jagadesan commented 1 year ago

i have uploaded my sample application https://github.com/JP-Jagadesan/mfe/tree/master.