It looks like adding the package name to a “whitelistedNonPeerDependencies” collection in the ng-package.json file will resolve this build issue. I’m still not sure what the best practice is here though. Should we create angular libraries that have dependancies on other npm packages or is it best to only have peerDependancies?
ng-package.json file:
{
"$schema": "../../node_modules/ng-packagr/ng-package.schema.json",
"dest": "../../dist/ikr-lib",
"deleteDestPath": false,
"lib": {
"entryFile": "src/public_api.ts"
},
"whitelistedNonPeerDependencies": [
"element.ui"
]
}