You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Configuration 'production' could not be found in project 'my-lib'.
Error: Configuration 'production' could not be found in project 'my-lib'.
at Architect.getBuilderConfiguration (C:\code\my-app\node_modules\@angular-devkit\architect\src\architect.js:102:23)
at MergeMapSubscriber._loadWorkspaceAndArchitect.pipe.operators_1.concatMap [as project] (C:\code\my-app\node_modules\@angular\cli\models\architect-command.js:70:55)
at MergeMapSubscriber._tryNext (C:\code\my-app\node_modules\rxjs\internal\operators\mergeMap.js:65:27)
at MergeMapSubscriber._next (C:\code\my-app\node_modules\rxjs\internal\operators\mergeMap.js:55:18)
at MergeMapSubscriber.Subscriber.next (C:\code\my-app\node_modules\rxjs\internal\Subscriber.js:64:18)
at TapSubscriber._next (C:\code\my-app\node_modules\rxjs\internal\operators\tap.js:62:26)
at TapSubscriber.Subscriber.next (C:\code\my-app\node_modules\rxjs\internal\Subscriber.js:64:18)
at MergeMapSubscriber.notifyNext (C:\code\my-app\node_modules\rxjs\internal\operators\mergeMap.js:84:26)
at InnerSubscriber._next (C:\code\my-app\node_modules\rxjs\internal\InnerSubscriber.js:25:21)
at InnerSubscriber.Subscriber.next (C:\code\my-app\node_modules\rxjs\internal\Subscriber.js:64:18)
Desired functionality
According to create library story in wiki documentation, to publish my library I should run ng build my-lib --prod. ("The --prod flag should be used when building to publish because it will completely clean the build directory for the library beforehand, removing old code leftover code from previous versions.")
As far as I can tell, generate library has since been updated to not add a production configuration for the project, and to just make the regular build clear dist/my-lib.
So the documentation should be updated to reflect this.
But I am not an Angular expert and I would like to be sure whether when an application which includes the library is built with --prod, the typical benefits of it (AOT, etc.) are still provided to the library code and not just the application code.
Bug Report or Feature Request (mark with an
x
)Command (mark with an
x
)Versions
Windows 10.
Repro steps
ng new my-app
cd my-app
ng generate library my-lib
ng build my-lib --prod
The log given by the failure
Desired functionality
According to create library story in wiki documentation, to publish my library I should run
ng build my-lib --prod
. ("The--prod
flag should be used when building to publish because it will completely clean the build directory for the library beforehand, removing old code leftover code from previous versions.")As far as I can tell,
generate library
has since been updated to not add a production configuration for the project, and to just make the regular build cleardist/my-lib
.So the documentation should be updated to reflect this.
But I am not an Angular expert and I would like to be sure whether when an application which includes the library is built with
--prod
, the typical benefits of it (AOT, etc.) are still provided to the library code and not just the application code.Mention any other details that might be useful
Possibly #10710 related.
The text was updated successfully, but these errors were encountered: